If one angle is

2x+y and the other angle is
10x-4y

how do you solve it? They are both right angles. Do you set them equal to each other?

yes. all right angles are equal to each other. So,

2x+y = 90
10x-4y = 90

y = 40
x = 25