Hot water always has more energy than cold water, whether by molecule or by volume. Firstly, consider this by molecule, or equivalently, by mass or by mole. Imagine a block of ice of mass m at absolute zero. read more
Energy of an object equals the sum of its rest mass and the kinetic energy. The hot and cold water with same amount of molecules have same rest mass, but kinetic energy of hot water is bigger because hot water molecules are moving faster than cold water molecules. So hot water has more energy than cold one. read more
The ocean has more thermal energy than the boiling pot of hot water because it has more molecules *(even though the molecules are moving slower than the boiling pot of water), which equals MORE total kinetic energy. read more