This question was asked in Example 1
Can you explain substitution and elimination method
Aryan Vatshyan's image