// Partial class definitions for the Astro503 blackjack programming project. class Card { public: enum Suit { Spades, Hearts, Clubs, Diamonds }; enum Value { Ace, Two, Three, Four, Five, Six, Seven, Eight, Nine, Ten, Jack, Queen, King }; Suit getSuit() const; Value getValue() const; friend class Deck; private: // You fill this in! }; class Deck { public: Deck(int nDecks=1); // Initialize deck with 52*nDecks cards ~Deck(); void shuffle(); // Randomize the order of cards Card draw(); // Get next card from the deck Card peek() const; // Look at next card but leave atop deck int cardsLeft() const; // How many cards left in deck private: // You fill this in! }; class Hand { private: const static int MAXCARDS=22; int n; Card cardArray[MAXCARDS]; public: int nCards() const {return n;} Card getCard(int i) const {return cardArray[i];} // Check for valid i??? void add(Card c); int blackJackValue() const; // Blackjack sum, aces take highest useful value bool isSoft() const; //Return true if value could be 10 less due to ace. void clear(); //Throw away cards, start over with empty hand. }; class Player { public: const Hand& getHand() const; void addCard(Card d); //add new card to hand // Return true if Player wants another card: bool drawAgain(const Hand& dealerHand); private: Hand h; // ... }; class Dealer { public: const Hand& getHand() const; void addCard(Card d); // Return true if dealer should draw another card: bool drawAgain(const Hand& dealerHand); private: Hand h; // .... };