import math

a = math.pi/3
u = 7
v = math.sqrt(58-42*math.cos(a))

for n in range(49):
    w = math.sqrt(2*v*v-u*u+18)
    u = v
    v = w

print(w)