Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

USE C++ Getting Practice with Classes In order to get credit for the lab, you need to be checked off by the end of lab.

USE C++

Getting Practice with Classes

In order to get credit for the lab, you need to be checked off by the end of lab. You can earn a maximum of 3 points for lab work completed outside of lab time, but you must finish before the next lab. For extenuating circumstances, contact your lab TAs and the instructor.

For this lab we would like to create the pieces necessary to make a variety of card games using a standard 52 card deck of playing cards.

(3 pts) Card Class

Design and create the .h and .cpp files with accessors and mutators for a Card class. Cards have two properties, suit and rank. The four possible suits are diamonds, clubs, hearts, and spades. There are 13 possible ranks, with the 11 corresponding to "Jack", 12 corresponding to "Queen", 13 corresponding to "King", and 1 corresponding to "Ace".

(3 pts) Deck Class

Design and create the .h and .cpp files with accessors and mutators for a Deck class. Decks are made up of 52 Cards. The Deck class should have functions for creating the deck (filling it with the traditional 52 cards), shuffling the cards, and printing the entire deck out to the terminal. (Links to an external site.)

(3 pts) Implementation

Now, create a driver.cpp file that creates a deck, shuffles the cards, and prints out the results.

(1 pt) Makefile

Create a Makefile that compiles all of your .cpp files and makes an executable showing off their functionality.

Remember, you will not receive lab credit if you do not get checked off by the TA before leaving each lab. Once you have a zero on a lab, then it cannot be changed because we have no way of knowing if you were there or not!

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

Oracle 10g SQL

Authors: Joan Casteel, Lannes Morris Murphy

1st Edition

141883629X, 9781418836290

Students also viewed these Databases questions

Question

2. Provide recommendations for effective on-the-job training.

Answered: 1 week ago