As charge is quantized, the least amount of charge that can be transferred is e.
According to the question, energy lost is completely transferred in the form of the photon.
Please note that the energy is lost as conservative forces are considered to be negative if they are attractive in nature.
As electric potential energy =
And energy of the photon =

We have :
Sustituting,

and discarding the minus sign, we get:
which implies,
Also,
