This program is a simplified version of the gambling card games Blackjack (a cloth for the table is supplied separately). The game works the following follows: players are dealt cards, each of which points are added. Each the player tries to earn 21 points, not more. For each card with the number given as many points as it is. The ACE is given either 1 point or 11 (depending on what suits the player more), and for the Jack, Queen and King 10 points.
The computer is the dealer (the casino) plays against a group from one to seven players. In the beginning of the stake, all parties (including the dealer) receives two cards.
Players can see all your cards, as well as the amount of points. However, one of the cards the dealer is hidden throughout the con.
Next, each player gets the opportunity to take additional cards until long as he doesn't get bored. If the total score of the player exceeds 21 (this situation is known as the bust), the player loses. After all the players had the opportunity
to gain additional cards, the dealer reveals the hidden card. Further he is obliged to take new cards as long as the sum of its points is less than or equal to 16.
If the dealer goes bust, all players who have not bust win. Otherwise, the sum of points for each of the remaining players is compared to the amount of points the dealer. If the total score of the player is greater than the sum of dealer's points, he wins. Otherwise, the player loses. If the amount of points the player and dealer are equal, a draw is counted (this is called a push).
MIT License
Copyright (c) 2017 Ivan Chapkailo
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Before game, please, enable CapsLock key and True Type font in console for right representation of game.
