Assist in coding to create higher or lower game.
Display the screen to enter users name and showing a welcome 'banner'
After the user enters there name
Ask the player to a guess a number between 1 - 20
which then has 5 attempts to guess the number
user guess and enter random number
Logic
If user answer > Random imported number
reply = Your guess is to high the answer is lower
elif user answer < Random imported number
Reply = Your guess is to low the answer is higher
elif user answer == random imported number
reply = Well done your answer is correct
while also deducting a guess each time
else if user runs out of guess
reply = unlucky your out of guesses
break
Then ask the user if he wants to play again
if yes then play again
if no Break
Then display a goodbye 'banner'
Display the screen to enter users name and showing a welcome 'banner'
After the user enters there name
Ask the player to a guess a number between 1 - 20
which then has 5 attempts to guess the number
user guess and enter random number
Logic
If user answer > Random imported number
reply = Your guess is to high the answer is lower
elif user answer < Random imported number
Reply = Your guess is to low the answer is higher
elif user answer == random imported number
reply = Well done your answer is correct
while also deducting a guess each time
else if user runs out of guess
reply = unlucky your out of guesses
break
Then ask the user if he wants to play again
if yes then play again
if no Break
Then display a goodbye 'banner'
Yoriz write Mar-13-2023, 06:23 AM:
Moved to homework:
Moved to homework:
https://python-forum.io/misc.php?action=help&hid=52 Wrote:Homework and No Effort Questions
This forum is focused on education. It exists to help people learn Python. We don’t exist to solve others' problems.