I am thinking of implementing blackjack. I have come up with the following set of rules:
1) Hand: Cards held by a player. For it to be a winning hand, must be greater than dealer hand or dealer must bust.
2) Dealer deals cards one by one to player(s) in clock-wise direction(for 2 rounds)
3) The dealer finally deals the face-up card to himself.
4) After looking at their hand players can 'stand'(ask dealer not to deal anymore cards) or 'hit'(deal one card everytime
the option is chosen).
5) 10 and 'A' is a blackjack hand, takes precedence over other 21 pt hands and hence a winning hand.
6) 'A' can take 1 or 11 based on the other cards in a hand. A player cannot bust if one of the cards is 'A'
out of the two initially dealt cards, when he goes for a hit.
7) A hand with 'A' and another card is a 'soft' hand. Otherwise it is called a 'hard' hand.
8) After all the player(s) have finished playing, the dealer deals cards for himself until his hand is >= 17(Only if he has a 'hard' hand)
9) After point 8, the 5 possible outcomes are:
Dealer hand less than Player hand.(Player win)
Dealer hand more then Player hand.(Dealer win)
Dealer hand busts.(Player win)
Player hand busts.(Dealer win)
Player hand and dealer hand are equal and they split the wagered amount
Thank you, Fred. No, I just read the rules on-line and intended to write down the actual casino rules. But I am not sure if I should try to implement the whole game as played in a casino. Kindly let me know if there is a "subset" that I can start with.