Step 4 – keep track of guesses
The final thing to do is keep track of the number of guesses needed.
- set up a variable called guesses at the top of the program with the value 0
- inside the while loop, add a line of code to add one to guesses
- after the while loop tell the user how many guesses they took
There's a way to add one to a variable which is really important...
Think about what else you could add to your program...