/* Header File for playing card types and functions */ /* Define a type for the rank of a playing card */ typedef enum { Ace, Two, Three, Four, Five, Six, Seven, Eight, Nine, Ten, Jack, Queen, King } Rank; /* Define a type for the suit of a playing card */ typedef enum { Clubs, Spades, Diamonds, Hearts } Suit; /* Define a type for all 52 playing cards */ typedef enum { ca, c2, c3, c4, c5, c6, c7, c8, c9, ct, cj, cq, ck, sa, s2, s3, s4, s5, s6, s7, s8, s9, st, sj, sq, sk, da, d2, d3, d4, d5, d6, d7, d8, d9, dt, dj, dq, dk, ha, h2, h3, h4, h5, h6, h7, h8, h9, ht, hj, hq, hk } Card; /* Display the name of a rank as an english word. */ void show_rank( /* in */ Rank rank ); /* Display the name of a suit as an english word. */ void show_suit( /* in */ Suit suit ); /* Given a Card, return its rank */ Rank get_rank( /* in */ Card card ); /* Given a Card, return its suit */ Suit get_suit( /* in */ Card card ); /* Return a randomly selected Card */ Card get_random_card();