The equation is already set up for you. All you need to do is solve for x, the number of hours.
23 + 3x = 5x + 7 original equation
23 - 7 = 5x - 3x combine like terms by subtracting 7 and 3x from both sides
16 = 2x simplify
16/2 = x divide both sides by 2 to isolate x
8 = x solve for x
Therefore, the answer is 8 hrs.