if you are given with X = 2y than
2x + 5y = 9
2(2y) + 5y = 9
4y + 5y = 9
9y = 9
y = 9/9
y = 1
putting the value of y in 1st equation so
X = 2y
X = 2(1)
X = 2