draw a 2D diagram like this: ABCD is a rectangle where AB=8, BC=15 and BC is first on the ground level, now rotate the rectangle around point C so that point A is 12 above the ground.
solve the 2D problem and we can manage to establish the equation
and the exact solution is