Answer:
a pair of glasses costs $17
a hat costs $21
Explanation:
h = hat
g = glasses
3h + 4g = 123
1h + 3g = 66
multiply the 2nd equation by 3
3h + 9g = 198
negate everything in the 1st equation and add it to the 'new' 2nd equation
3h + 9g = 198
+ -3h - 4g = -123
5g = 75
g = 15
substitute the 15 in either one of the 1st equations
1h + 3(15) = 66
h + 45 = 66
h = 66-45
h = 21
to check, substitute both g=15 and h=21 into BOTH 2 original equations.