Let x = distance from the base of the wall to the top of the ladder.
The ladder, wall, and ground form a right triangle with legs of lengths
x feet and 6 feet and hypotenuse of length 16 feet.
By the Pythagorean Theorem, x2 + 62 = 162.
x2 + 36 = 256
x2 = 220
x ≈14.8 feet