Hello. This is question for my course work, I was wondering if I could get some insight, here is the question:

Assume that the vast majority of the photons in the present Universe are cosmic microwave radiation photons that are a relic of the big bang. For simplicity, also assume that all the photons have the energy corresponding to the wavelength of the peak of a 2.73K black-body radiation curve. At Approximately what redshift will the energy density in radiation be equal to the energy density in matter?

(hint: work out the energy density in photons at the present time. Then work it out for baryons, assuming a proton for a typical baryon. Remember how the two quantities scale with redshift to work out when the energy density is the same.)

How do I work out the energy density of a photon and a proton? Do I use E = mc^2?