So first I recommend you line it up like this:
y=x+2
y=2x-5
So, you can plug in y (probably the one that equals x+2) and the equation turns into:
x+2=2x-5
You subtract x from both sides and get:
2=x-5
then, you add 5 to both sides:
x=7
And that is what x equals.