Solve the system of linear equations by substitution.
x+4y=14
3x+7y=22
x+4y=14
3x+7y=22