bwukki

Untitled

Apr 17th, 2018
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.67 KB | None | 0 0
  1. //Card.h
  2. #ifndef CARD_H
  3. #define CARD_H
  4. #include <iostream>
  5. #include <sstream>
  6.  
  7. static std::string suits[4] {"Diamonds","Clubs","Hearts","Spades"};
  8. static std::string faces[13] {"Ace", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight", "Nine", "Ten", "Jack", "Queen", "King"};
  9.  
  10. enum face { Ace, Two, Three, Four, Five, Six, Seven, Eight, Nine, Ten, Jack, Queen, King};
  11.  
  12. enum suit { Diamonds, Clubs, Hearts, Spades};
  13.  
  14. class Card
  15. {
  16.     public:
  17.         Card(face,suit);
  18.         Card();
  19.         ~Card();
  20.         std::string toString();
  21.         void setVal(face,suit);
  22.  
  23.     protected:
  24.  
  25.     private:
  26.     face cardFace;
  27.     suit cardSuit;
  28. };
  29.  
  30. #endif // CARD_H
Add Comment
Please, Sign In to add comment