Computers and Technology

You wrote a program to allow the user to guess a number. Complete the code. while keepGoing:
guess = input("Guess an integer from 1 to 10: ")
guess = int(guess)
attempts = attempts + 1
if guess == correct:
print("You were correct!")
keepGoing =
else:
if guess < correct:
print("Guess higher.")
else:
print("Guess lower. ")

answer
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 00:40, laurenrubin18
Write a function 'music_func' that takes 3 parameters -- music type, music group, vocalist -- and prints them all out as shown in the example below. in case no input is provided by the user, the function should assume these values for the parameters: "classic rock", "the beatles", "freddie mercury". for example: input: alternative rock, pearl jam, chris cornell output: the best kind of music is alternative rock the best music group is pearl jam the best lead vocalist is chris cornell note: the print statements will go inside the for example: print("the best kind of music is"
Answers: 2
image
Computers and Technology, 23.06.2019 21:00, tiffg2588
Will this setup result in what kathy wants to print?
Answers: 2
image
Computers and Technology, 24.06.2019 06:30, chloeholt123
For which utilities, if any, does the landlord pay?
Answers: 2
image
Computers and Technology, 24.06.2019 16:30, magalya01
Which program can damage your computer?
Answers: 1
Do you know the correct answer?
You wrote a program to allow the user to guess a number. Complete the code. while keepGoing:
...

Questions in other subjects: