Do x-rays and gamma rays also contain photons like visible light does? If so, then what makes photons of visible light and other waves different?
The rest mass of a photon is zero, but as it moves at the speed of light, its mass is infinite. By $E=mc^2$, its energy is infinite, but using formula $ E=h\nu$, we get finite energy. How is this happening?