s a deck of 52 cards and asks the name of the two players and makes both players draw five cards from the deck. What I want to be added into the code is that both Players are human that manuelly pick which cards they pick instead of it automatically choosing itself and Player A starts. Player A picks a card in his/her hand. Player B gets to choose the two cards which add to the value of Player A’s card, if player B lies and the two cards they choose do not add up to A's card, player B loses a point, if player B does not have two cards whose value adds to the value of Player A’s card, then no one gets a point. Player’s A card (if selected) and the two cards from
For the code in java below it shows a deck of 52 cards and asks the name of the two players and makes both players draw five cards from the deck.
What I want to be added into the code is that both Players are human that manuelly pick which cards they pick instead of it automatically choosing itself and Player A starts. Player A picks a card in his/her hand. Player B gets to choose the two cards which add to the value of Player A’s card, if player B lies and the two cards they choose do not add up to A's card, player B loses a point, if player B does not have two cards whose value adds to the value of Player A’s card, then no one gets a point. Player’s A card (if selected) and the two cards from Player B are discarded both players draw back to 5 cards from the deck.
Main class code:
Step by step
Solved in 2 steps