Looking at the triangle on the left, we can write its base as 50 - x
And, using the Pythagorean Theorem , we can solve this :
(50 - x)^2 + 30^2 = x^2 simplify
x^2 - 100x + 2500 + 900 = x^2 subtract x^2 from both sides
-100x + 3400 = 0
3400 = 100x divide both sides by 100
34 = x = AB