A gardener was tasked with planting flowers in rows, each row containing the same number of plants. When he arranged them in rows of 6, 8, 10, or 12, there were always 5 plants left unplanted. However, when he planted them in rows of 13, no plants remained unplanted. How many plants did the gardener have in total?
Explanation
The total number of plants leaves a remainder of 5 when divided by 6, 8, 10, and 12, but is exactly divisible by 13. The number 845 satisfies these conditions, making it the correct total number of plants.