Help on exercise 36


I am creating a game similar to the one in exercise 35 but I am stuck. The first part of my code is doing what I want but I’m struggling a lot with the second function, trying to fix it. If you can help me, highlighting what I’m doing wrong, it would be great.
Thank you.

That function looks weird to me. Can you say specifically what you want it to do and what it does now, and provide a sample output/session?

At the end I made it with a single while loop inside the function. Thank you the same for your time.

A free service run by Zed A. Shaw for