A PHP Error was encountered

Severity: Warning

Message: fopen(/tmp/ci_sessionu8jbf1clgvdottni2oke47soe468e01a): failed to open stream: No space left on device

Filename: drivers/Session_files_driver.php

Line Number: 176

Backtrace:

File: /var/www/html/application/controllers/Project.php
Line: 10
Function: __construct

File: /var/www/html/index.php
Line: 311
Function: require_once

A PHP Error was encountered

Severity: Warning

Message: session_start(): Failed to read session data: user (path: /tmp)

Filename: Session/Session.php

Line Number: 143

Backtrace:

File: /var/www/html/application/controllers/Project.php
Line: 10
Function: __construct

File: /var/www/html/index.php
Line: 311
Function: require_once

Guessing Game in Python | Sudheer
Coders Packet

Guessing Game in Python

By Balaboina sudheer kumar

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.

 

Guessing Game in python

Download Complete Code

Comments

No comments yet

Download Packet

Reviews Report

Submitted by Balaboina sudheer kumar (Sudheer)

Download packets of source code on Coders Packet