x = rate of mechanic who worked 5 hours
y = rate of mechanic who worked 15 hours
Then
x + y = 235
5x + 15y = 2375
Just solve these 2 equations above for x and y.
x + y = 235 ⇒ x = 235 - y
Substitute into second equation to find y.
5(235 - y) + 15y = 2375
1175 - 5y + 15y = 2375
10y = 1200
y = 1200/10 = 120
x = 235 - y = 235 - 120 = 115
The mechanic who worked 5 hours charged $115 per hour, the one who worked 15 hours charged $120 per hour.