Let x+2y=2 ...(1)
and 2x+y=7 ...(2)
From equation (2), find the value of x in terms of y
x=7−y2 ...(3)
Substituting x=7−y2 in equation (1), we get
⇒ (7−y2)+2y=2
⇒72−y2+2y=2
⇒2y−y2=2−72
⇒3y2=−32
⇒y=−1
Substituting y=−1 in equation (3),
x=7−(−1)2
⇒x=4
Therefore the value of x+y is 4+(−1)=3.