A spherical ball of mass is stationary at the top of a hill of height . It rolls down a smooth surface to the ground, then climbs up another hill of height and finally rolls down to a horizontal base at a height of above the ground. The velocity attained by the ball is