Question: help me please, I am lost In this assignment you will implement a representation of a hand in a Blackjack card game. You are to

help me please, I am lost help me please, I am lost In this assignment you will implement

In this assignment you will implement a representation of a hand in a Blackjack card game. You are to modela card and a hand of cards. Classes to Implement: Card.java Hand.java Tester.java Card value: ant + Card (int value) + getValue(): int Card - Constructor should accept values 1 - 11. getValue() - Gets the value of the card. Hand hand: Card[12] numberOfCards: int + Hand () + addCard (Card card) : void + getNumberOfCards(): int + clear(): void + c culateTotal (): int . . . hand - Holds up to 12 cards in the hand. numberofCards - Number of cards in the hand. addCard (Card card) Adds the given card to the hand. getNumberoCards () - Gets the number of cards in the hand. clear() - Makes the number of cards in the hand o. calculateTotal () - Gets the total of the hand. . . Test.java . include a main method where you test that all your methods work as expected. Test different scenarios - I.e. Get total and number of cards of a hand with no cards. Add 1 card and the total of the hand should be to that cards value and number of cards should be 1 Clear the hand and ensure that the total value and the number of cards is 0. Note: I will use my own Test class to test your card and Hand classes. o o O

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!