Final answer:
By setting up an equation to determine when the temperatures in the two towns will be equal, we find that the number of hours, h, needed is 5. However, this result is not among the options provided, suggesting there may be a typo in the question or the options.
Step-by-step explanation:
To find out after how many hours, h, the temperatures in the two towns will be equal, we can set up an equation where the temperature in the first town equals the temperature in the second town. The first town's temperature is rising from 20 degrees by 5 degrees each hour, so its temperature after h hours is 20 + 5h. The second town's temperature is rising from 30 degrees by 3 degrees each hour, resulting in a temperature of 30 + 3h after h hours.
We can now equate these two expressions to find h. So, 20 + 5h = 30 + 3h. Solving for h, we subtract 3h from both sides, which gives us 2h on the left, and subtract 20 from both sides, giving us 10 on the right. Therefore, 2h = 10, and dividing both sides by 2 gives us h = 5. However, this result is not listed as one of the options. Let's review our calculations and check for any mistakes.
After reevaluating the calculations, we see that we should actually end up with:
20 + 5h = 30 + 3h
5h - 3h = 30 - 20
2h = 10
h = 10 / 2
h = 5
It seems there might have been a typo in the initial question or the given options since h = 5 is the correct answer, but it is not one of the options given.