Houston College Python IDLE Hi Lo Guessing Game Project
Question Description
Have the computer generate a random number* between 1 and 100. This will now be the secret number.?
Use a for loop to allow users to have 10 chances to guess the number (you can use a while loop if desired to give user unlimited tries, ex: while user has not guessed the number). ?
Prompt user for a number between 1 and 100. ?
Read in the number. ?
If the number is less than the secret number, print a message stating its too low.?Else if the number is higher than the secret number, print a message stating its too high.?Else if the number is == to the secret number, then print an appropriate message and exit*
For example, to generate a random number between 1 and 10, you will need the following code:import random secret_number = random.randint(1,10)
Have a similar assignment? "Place an order for your assignment and have exceptional work written by our team of experts, guaranteeing you A results."