Csis1101- write python code to implement a basic number


Assignment- Guessing Game

Write Python code to implement a basic number guessing game.

The program will choose a random number between 1 and 9 (inclusive) using randint() . The user will be prompted up to 3 times to choose a number. Each time the program will print out "Too High" or "Too Low", or "You Win" depending on the relative value.

If the person completes three attempts without guessing the value, the program will print "You Lose" and end.

Several examples of output are shown below:

Code which may help you:

#example that prints a pseudo-random number
from random import randint
print("Starting Program")
print(randint(0,9))

Attachment:- Python_Project.rar

Solution Preview :

Prepared by a verified Expert
Python Programming: Csis1101- write python code to implement a basic number
Reference No:- TGS02240731

Now Priced at $25 (50% Discount)

Recommended (99%)

Rated (4.3/5)