A man buys a carton of 200 cigarettes, and every day he smokes seven cigarettes less than the day before. Eventually the day arrives when his quota is down to one cigarette—which happens to be all that there is left in the original carton.
How many a day was he smoking he bought the carton?
(Source: Math and Logic Puzzles for the PC Enthusiast by J.J. Clessa)
This puzzle is another one where one has to work backwards. I did it in Python:
Here's the outcome:Smoked 1 on day 0, with a total of 1 Smoked 8 on day -1, with a total of 9 Smoked 15 on day -2, with a total of 24 Smoked 22 on day -3, with a total of 46 Smoked 29 on day -4, with a total of 75 Smoked 36 on day -5, with a total of 111 Smoked 43 on day -6, with a total of 154 Smoked 50 on day -7, with a total of 204The last day exceeds 200 a little but the solution towards the end of the book confirms that my figure is correct, stating that "he also had four cigarettes left over from his last packet".
No comments:
Post a Comment