Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please seperate those 5 files clearly Thanks! Create a program to shuffle and deal a deck of cards. The program should consist of class Card,

Please seperate those 5 files clearly Thanks!image text in transcribed

Create a program to shuffle and deal a deck of cards. The program should consist of class Card, class Deck Of Cards and a driver program. Class Card should provide: a) Data members face and suit of type int. b) A constructor that receives two ints representing the face and suit and uses them to initialize the data members. Class Deck Of Cards should contain: a) Two Card objects named deck to store two cards. c) A constructor that takes no arguments and initializes both cards in the deck. You can give these two cards a random face value and suit value, but make sure they are not the same. d) A print Cards function that prints the two cards. The driver program should create a Deck Of Cards object, and print the cards that this object has. You need to have 5 files in this project: card.hpp, card.cpp, deckofcards.hpp, deckofcards.cpp, main.cpp Create a program to shuffle and deal a deck of cards. The program should consist of class Card, class Deck Of Cards and a driver program. Class Card should provide: a) Data members face and suit of type int. b) A constructor that receives two ints representing the face and suit and uses them to initialize the data members. Class Deck Of Cards should contain: a) Two Card objects named deck to store two cards. c) A constructor that takes no arguments and initializes both cards in the deck. You can give these two cards a random face value and suit value, but make sure they are not the same. d) A print Cards function that prints the two cards. The driver program should create a Deck Of Cards object, and print the cards that this object has. You need to have 5 files in this project: card.hpp, card.cpp, deckofcards.hpp, deckofcards.cpp, main.cpp

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beyond Big Data Using Social MDM To Drive Deep Customer Insight

Authors: Martin Oberhofer, Eberhard Hechler

1st Edition

0133509796, 9780133509793

More Books

Students also viewed these Databases questions

Question

=+How have the changes in MNEs affected IHRM?

Answered: 1 week ago