Imagine earth to be a solid sphere of mass M and radius R. If the value of acceleration due to gravity at a depth 'd' below earth's surface is same as its value at a height 'h' above its surface and equal to (where g is the value of acceleration due to gravity on the surface of earth), the ratio of will be:
Solving we get