Higher or Lower Number Game

Higher-Or-LowerFor this challenge you will design and write a program to play against the computer. The computer will display a random number between 1 and 100. The user will have to try to guess this number. For each guess the computer will inform the user if the number to guess is higher or lower than the user guess. The program will end once the user guess matches the number to guess.

Learning Objectives

By completing this challenge you are going to use selection (IF statements) and iteration (While loop). You will use comparison operators such as > , < and == to compare numbers. You will use variables to store the value of a random number and retrieve user inputs.

Task 1: Flowchart

Use our online Flowchart Studio tool to create the flowchart for this algorithm:
Online Flowchart Creator guess-the-number-while-loop-flowchart

Task #2: Complete the Python Code



The solution for this challenge is available to full members!
Find out how to become a member:
➤ Members' Area
Tagged with: , ,