Write an xbasic script that solves this puzzle using a For / Next loop. Include comments so the "professor" can figure out what you're doing without losing any more of his quickly disappearing hair! Display your result in a message box on screen. For extra credit write your result to the trace window, too.
Puzzle 23:
Jennifer arranged for a party and had a basket of strawberries to serve. She ate 5 strawberries before the party began, and gave a friend 3 more. Eight girls came to the party. The first girl took one strawberry. The second girl took three. The third girl took five, and so on. Her basket was empty after the last girl took hers. So, how many strawberries did she start with?
Have fun!
Puzzle courtesy easycalculation.com
Bookmarks