Question: Starting with the UML object model from Exercise 8 , add a player and a dealer object to the model. The player object will represent
Starting with the UML object model from Exercise
add a player and a dealer object to the model. The player object will represent each player in the game. A player will need to be able to add cards to its hand, get the hand total, and have a name. The dealer object represents the dealer, which will control the overall game play. The dealer will handle the deck, manage players, contain its own hand, do the start deal, and determine winning players hands.
Write a main program that will prompt the user for the number of players
there can be up to six players in the game
get the name of each player, display all the hands
remember that the second card of the dealer is not displayed until the hand is over
ask each player to hit until they stop asking for hits, do the dealer hit
dealer must hit if hand total is less than
show all hands and who wins
players with higher total and dealer
Starting with the UML object model from Exercise
add a player and a dealer object to the model. The player object will represent each player in the game. A player will need to be able to add cards to its hand, get the hand total, and have a name. The dealer object represents the dealer, which will control the overall game play. The dealer will handle the deck, manage players, contain its own hand, do the start deal, and determine winning players hands.
Write a main program that will prompt the user for the number of players
there can be up to six players in the game
get the name of each player, display all the hands
remember that the second card of the dealer is not displayed until the hand is over
ask each player to hit until they stop asking for hits, do the dealer hit
dealer must hit if hand total is less than
show all hands and who wins
players with higher total and dealer
IN JAVA
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
