there's more than 1 way to skin a cat.
If you focus on the 39 deg angle, then x is "adj" to that angle and 10 is "opp."
10
Then tan 39 deg = -------- Solve this for x.
x
x
If you focus on the 51 deg angle, then tan 51 deg = ------
10
Solve this for x. You MUST obtain the same value for x, either way.