We have the next equations
y=3x-14 ... (1)
y=x-10 ... (2)
we will substitute the value of y of the first equation into the second equation

we sum the terms with x and the terms without x

then we substitute the value of x in the first equation

the solution of the system of equations is
x=2 , y=-8