// // deck class for WAR card game // // Described in Chapter 2 of // Data Structures in C++ using the STL // Published by Addison-Wesley, 1997 // Written by Tim Budd, budd@cs.orst.edu // Oregon State University // # include #include "card.h" using namespace std; class Deck { public: // constructor Deck ( ); // operations void shuffle ( ) // need to do a simpler way !!! { random_shuffle (cards, cards+52, randomizer); } bool isEmpty ( ) { return topCard <= 0; } Card draw ( ); protected: Card cards[52]; int topCard; };