-
This is a 2-player game.
-
There are 6 face dice which are being rolled by the players to their chance.
-
The player starts from 0 and has to reach the final position (in our case, it's 100).
-
There are some ladders which turn out to be lucky for the player as they shorten the way.
-
There are some snakes present in between the game which turns out to be the enemy of the player as they just lengthen their way to 100.
-
The position of snakes and ladders are not visible to players, ofcourse (but you can always have a look in the code).
-
Firstly, the game will ask to input the names of the players.
-
The game will alternate between these 2 players. For a particular player’s chance, it will ask for auto mode OR manual mode.
-
If the player enters "manual" mode, he is then prompted to enter any number from 1-6 to move.
-
If the player enters "auto" mode, then he will be prompted to continue the game by rolling OR quit the game.
-
For continuing the game, the player should type "roll" (excluding quotes), then a random number will be generated between 1 and 6 (both inclusive) and the game continues.
-
For quitting the game, the player should type "quit" (excluding quotes), which will automatically declare the opponent as the winner.
-
-
-
After each turn, the game will display the player's final position as a sum of last position and value of current chance.
-
If either of the players reaches position 100, then that player will win and it will display which player won the game.
- Remember not to overshoot the position 100. For example, if current position is 97 and value of dice is 6, then position will be the same i.e. 97 as 97+6 = 103 which is not possible.