Skip to content

Aditi-Asati/21_number_game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

21 Number Game

21, Bagram, or Twenty plus one is a game which progresses by counting up 1 to 21, with the player who calls “21” is eliminated. It can be played between any number of players.

Implementation

This is a simple 21 number game using Python programming language. The game illustrated here is between the player and the computer.

  1. The player can choose to start first or second.
  2. The list of numbers is shown before the Player takes his turn so that it becomes convenient.
  3. If consecutive numbers are not given in input then the player is automatically disqualified.
  4. The player loses if he gets the chance to call 21 and wins otherwise.

Free bonus tip ;)

Winning against the computer can be possible by choosing to play second. The strategy is to call numbers till the multiple of 4 which would eventually lead to 21 on computer hence making the player the winner (Thank me later!)

About

No description or website provided.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages