Let be:
• r: The price of a grade of regular gasoline.
,
• p: The price of a grade of premium gasoline.
Then, from the word problem, we know that:

Thus, we can write the following equation:

Now, we can solve the above equation for r:

Finally, we replace the value of r in Equation 1, and we solve it for p:

Therefore, the price of a grade of regular gasoline is $3.94, and of a grade of premium gasoline is $4.16.