Final answer:
To find the number of pencils in each cup, we can set up equations representing the number of pencils in each cup and solve them. The first cup contains 7 pencils, the second cup contains 8 pencils, and the third cup contains 9 pencils.
Step-by-step explanation:
To solve this problem, we can set up equations representing the number of pencils in each cup. Let's assume the first cup contains 'x' pencils. The second cup contains one more pencil than the first cup, so it contains 'x + 1' pencils. The third cup contains one more than the second cup, so it contains 'x + 1 + 1 = x + 2' pencils.
We know that the total number of pencils is 24, so we can set up an equation: x + (x + 1) + (x + 2) = 24. Simplifying this equation, we get 3x + 3 = 24. Subtracting 3 from both sides, we have 3x = 21. Dividing by 3, we find that x = 7.
Therefore, the first cup contains 7 pencils, the second cup contains 7 + 1 = 8 pencils, and the third cup contains 7 + 2 = 9 pencils.