Objectives
Your group, using the starter code that I have provided, will implement a console-based game in the style of casino Blackjack.
TIP: If you are having trouble seeing the UTF-8 card symbol characters in the file, just right-click the link above and choose "Save Link As" instead. Card symbols in Unicode: https://en.wikipedia.org/wiki/Playing_cards_in_Unicode
Criteria
Your program should be able to deal with the following:
- Games consist of multiple rounds, in the familiar "play again?(y/n): " style prompt.
- The deck should be fairly shuffled each round you play, before the cards are dealt (between hands).
- Deal cards clockwise, to the dealer's left. The first card the dealer gets is dealt face-down. Players can see both of their cards on-screen, and any other subsequent cards (a hit).
- Handling Blackjack properly (being dealt 21, an ace and a face card or 10), which means that the player wins immediately and the game is over unless the dealer is also dealt Blackjack. Note that the dealer doesn't show both of their cards until the hand is over.
- Handling a tie (called a push in Blackjack parlance).
- The dealer should stand on a 17 or higher, per casino rules. The dealer should only hit if they need to do so (they go last, so it will be clear if they do).
- If a player would bust (a score of 22 or more), but has any aces in their hand, then one or more aces should be treated as a 1 instead of an 11. Note that this isn't really a choice on part of the player. The game then continues as normal, and the player gets the opportunity to again hit or stand.
Bonus
You will be awarded a 5% bonus for each of the following:
- Accurately keeping track of wins, loses, and pushes for each player (and the house). Summarize this information at the end of each hand. You may find it useful to set the cout output width and alignment and/or use tab characters ('\t'). Express this in the form of both a raw number and a fixed-precision percentile of overall hands played (e.g., 66.67% for 2 hands won out of 3).
- Having a multiplayer mode with a prompt for 1-3 human players. They should be asked to either hit or stand in player order (in the physical world, turns proceed clockwise to the dealer's left).