This problem isn't really a Rate-of-Work Problem, it is actually a system of linear equations.
First Define your Variables, Let C be the Cost/Day for a Carpenter, and P be the Cost/Day for a Painter
Equation 1: 6c + 2p = 970
Equation 2: 3c + 4p = 770
Now you can solve this by grpahing, substitution or elimination, but for this answer, I will solve by elimination.
Choose one of your variables to get to be the same, I am going to choose C, so I need to multiply the Bottom equation by 2
6c + 2p = 970
2( 3c + 4p = 770 )
Now I get
6c + 2p = 970
6c + 8p = 1540
Subtract your two equations and you get -6p = -570, divide by -6 and P = 95.
That is, it cost $95.00/Day to hire a painter.
Now substitute P = 95 into one of your original equations
6c + 2(95) = 970
Simplfy 6c + 190 = 970
Subtract 190 from both sides 6c = 780
Dive by 6 on both sices c = 130
So it costs 130/day for a carpenter and 95/day for a painter.