We have to solve the system of linear equations:

x+y+2z=5 ...(1)

x+2y+z=8 ...(2)

2x+3y-z=1 ...(3)

(1) - (2)

=> -y + z = -3 ...(4)

(3) - 2*(1)

=> y - 5z = -9 ...(5)

(4) + (5)

=> -4z = -12

=> z = 3

y = -9 + 15 = 6

x = 5 - y - 2z = 5 - 6 - 6 = -7

**The solution to the system of equations is x = -7, y = 6 and z = 3**