In diagram A, the two angles can be referred to as Vertical Angles. Vertical Angles are congruent (equal) to each other, thus their measurements will be equal. So, for an equation, set the two angles equal to each other.
3x + 5 = 5x - 5
*subtract 3x from both sides*
5 = 2x - 5
*add 5 to both sides*
10 = 2x
*divide by 2 on both sides*
x = 5
The problem says to only solve for x, but if you had to solve for the angle you'd need to plug it in.
3(5) + 5 = 20
5(5) - 5 = 20
Therefore, it matches up! A simple way to check your work.