I've made a graph that represents the ladder and the wall. The ladder is positioned agains the wall in a 66º angle. As you can see they form a triangle, where the ladder is the hypotenuse and the wall represents the adjacent side of the angle.
To calculate the length of the hypotenuse of the triangle you can use trigonometry.
The cosine on an angle is defined as the ratio between the adjacent side and the hypothenuse:
Staring from this definition you can clear the length of the hypotenuse as:
The hypothenuse of the right triangle formed by the ladder, the wall and the floor is 27.04 meters.
The ladder measures 27.04meters.