and play only one game of craps or play multiple games set by the player.
- Object-Oriented Programming Principles;
- Collections Framework - ArraysList, LinkedList, HashMap and Set
- Recursion;
- Comparator and Iterator;
- Lambda functions, Streams and Method references;
- Third party libraries - Apache Commons Lang and Lombok;
Note
Project is 💯 delivered!
✅ Here is the loading effect (progress bar) when starting the application.
Loading The Game Of Craps
[################################### 89% ]
✅ Main menu after the loading bar completed and there is no registered player;
-------------------------------
# Playing The Game Of Craps #
-------------------------------
[ 1 ] Games To Be Played
[ 2 ] Play One Game
[ 3 ] Print Statistics
[ 4 ] Register Player
[ 5 ] Change Player
[ 6 ] Reset Games Statistics
[ 7 ] Print Players
[ 8 ] Help
[ 9 ] Quit
player: None
-------------------------------
provide an option:
✅ Register a player;
-------------------------------
# Playing The Game Of Craps #
-------------------------------
Add Player
In order to add a player please provide complete name, age, occupation separated by a comma.
player: None
-------------------------------
provide the necessary information to register a player or (quit/back):
✅ Set/Change a player after it is registered. You can have multiple registered players;
-------------------------------
# Playing The Game Of Craps #
-------------------------------
Change Player
[ 1 ] Valentin, Age: 35, Occupation: engineer
[ 2 ] Back
[ 3 ] Quit
player: None
-------------------------------
please choose a player from above or back/quit option:
✅ Set the numbers of games to be played and the loading effect with dots when setting the parameter;
-------------------------------
* Playing The Game Of Craps *
-------------------------------
Games To Be Played
Please you need to tell us how many games you want to be played. Statistics will be calculated.
player: Valentin
-------------------------------
provide requested information or back/quit: 50
50 games were selected to be played.......DONE
✅ Printing statistics for those 50 games played;
-------------------------------
* Playing The Game Of Craps *
-------------------------------
Playing 50 Games Of Craps
The Games Are Running..........DONE
Number of Wins per roll and chances for them:
Rolls Wins Chances
| 1 | 8 | 16.0%
| 2 | 7 | 14.0%
| 3 | 2 | 4.0%
| 4 | 0 | 0.0%
| 5 | 1 | 2.0%
| 6 | 0 | 0.0%
| 7 | 1 | 2.0%
| 8 | 1 | 2.0%
| 9 | 1 | 2.0%
| 10 | 1 | 2.0%
| 11 | 1 | 2.0%
| 12 | 0 | 0.0%
| 13 | 0 | 0.0%
| 14 | 0 | 0.0%
| 15 | 1 | 2.0%
-------------------------------
Number of Losses per roll and chances for them:
Rolls Losses Chances
| 1 | 5 | 10.0%
| 2 | 5 | 10.0%
| 3 | 4 | 8.0%
| 4 | 3 | 6.0%
| 5 | 1 | 2.0%
| 6 | 2 | 4.0%
| 7 | 2 | 4.0%
| 8 | 1 | 2.0%
| 9 | 1 | 2.0%
| 10 | 1 | 2.0%
| 11 | 1 | 2.0%
-------------------------------
Games Played / Wins / Losses / Chances For Winning / For Loosing
1. 50 24.0 26.0 48.0 52.0
-------------------------------
Games Played / Average length
1. 50 3.0
-------------------------------
✅ Choose what to do after stats are printed;
-------------------------------
* Playing The Game Of Craps *
-------------------------------
What To Do ?
[ 1 ] Play Again
[ 2 ] Return To How Many Games To Play
[ 3 ] Back To Main Menu
[ 4 ] Quit
player: Valentin
-------------------------------
please choose an option from above:
👉 You can check the rest of the functionalities if you clone this repo and try it.
Statistics
Social buttons
Repo metadata
Released under MIT by @valentinsoare 📫 Contact me