Im currently working on something that i really need help with. Im gonna make a while or do while loop that with the rand fuction generates random numbers between 1 and 100. When the random numbers hits 99 the loop should stop and the show the amount of attempts it took to hit the number 99 like this:
"It took 53 attempts to hit the number 99"
If someone could help me with a simple solution I would be so grateful!
A simple loop like this ought to do what you are after