This game is about the Guessing Game in python. We have to guess the number in five guessess.
The provided code implements a number guessing game in Python. The player is asked to guess a number between 1 and 10. The code generates a random number as the target. The player has a maximum of 5 guesses to correctly guess the number. Inside a while loop, the player enters their guess, which is compared to the random number. If the guess matches the target, the player is notified that they guessed correctly, and the loop is terminated. If the guess is incorrect, the player is informed and prompted to guess again. If the player runs out of guesses without guessing the correct number, a message is displayed indicating that they have exhausted their attempts and revealing the target number. The game concludes after the loop ends, providing the outcome of the game. This code allows users to engage in a simple yet entertaining number guessing game, challenging their luck and deductive skills as they attempt to guess the random number within the given number of tries.
Submitted by Balaboina sudheer kumar (Sudheer)
Download packets of source code on Coders Packet
Comments