Question
Array and Struct in Card applications: In card game design, card suit and face values can be defined with enumeration values. Declare suit values -
Array and Struct in Card applications:
In card game design, card suit and face values can be defined with enumeration values. Declare suit values - hearts, clubs, diamonds, spades using enum, declare face values of 2 10, Jack, Queen, King, Ace using enum
Declare a structure called Card, and it includes two data members, whose data types are the above two defined enumerations suit and face
typedef an array called Deck, and it includes all 52 cards, whose data type is the above defined Card structure
Write a function that fills a single card with user input from keyboard, using the above declared data structure, and one of parameters must be Card
Write a function that fills all 52 cards in a deck, using the above declared data structure, and one of parameters must be Deck
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started