Solving for y in terms of x simply means you want to know what y equals in respect to x.
x+y=5
You want to isolate y, because you want to know what y equals. So
y=5−x
What you do to one side, you must do to the other. Since you want to get y by itself, you have to eliminate the x. Since you subtracted x from one side, you have to do it to the other side, as well.
To look at this another way, let's say x=3 and y=2 .
If you still wanted to isolate y, you would do the same thing.
3+2=5
2=5−3