Let's say the hours the two mechanics worked are "a" and "b".
Then the cost of the first mechanic's time would be: 75a
And the cost of the first mechanic's time would be: 95b
Now you can write the equation for the total amount as:
75a + 95b = 2925
Additionally, we know that they spent a total of 35 hours
on the job. Therefore:
a + b = 35
Now we solve this equation for a:
a + b = 35 | - b
a = 35 - b
We can no substitute the a in the original equation with 35 - b
from this one and solve for b:
75a + 95b = 2925
75(35 - b) + 95b = 2925 | distribute
75*35 - 75*b + 95b = 2925
2625 - 75b + 95b = 2925 | combine like terms
2625 + 20b = 2925 | - 2625
20b = 300 | /20
b = 15
No substitute b with 15 in this equation...
a = 35 - b
...and solve for a:
a = 35 - 15
a = 20
The first mechanic worked 20 hours and the second worked 15 hours.