The work done to raise a mass m from the surface of the earth to a height h, which is equal to the radius of the earth, is
m g R
Work done =Change in potential energy
where M is the mass of earth and R is the radius of earth.
∴ W=GMm1R-1(R+h) Now, h=R ∴W=GMm1R-12R=GMm2R ⇒ W=mgR2 ∵ g=GMR2