Step 3 – compare the values
We need to compare the answer with theNumber.
We need to keep doing this so there needs to be a loop.
This is tricky, so don't worry if you can't manage all of it.
- set up answer with a value of 0 first of all
- use a while loop to compare answer with theNumber using != for not equal to
- move the input line inside the while loop
- use an if–else block to tell the user if they got it right or not
- run your program to check if it works
This is quite tricky to get right first time...