HtDP: Problem 9.5.5

In problem 9.5.5, I knew I wasn’t understanding something. I thought that I had followed the recipe, yet I couldn’t solve the problem. That alone was a red flag indicating that I most probably did not follow the recipe!
In this discussion everyone helped me to see what I was missing. The thing was that I was missing something about recursion, the fact that you can figure out what you need to do by combining this thing with the rest of the things.
To specific, the step that I had skipped was literally taking the expected data and using that to determine the combination that needs to occur within the program body. Before, my approach had always been to solve “the whole problem” at once for the recursive step. Following the recipe, you can much more easily see what you are missing.

Leave a Reply

Your email address will not be published. Required fields are marked *