Find Jobs
Hire Freelancers

Class Card

$30-5000 USD

Completed
Posted over 21 years ago

$30-5000 USD

Paid on delivery
1) Create a card class in C++. The class should have the following features: 1) String for the card suit (Diamond, Heart, Spade, Club) 2) Number for the card value (1 to 13) 3) Assessors to get the card suit and card value individually. 4) Constructor to create a card from a suit and number. 5) Copy constructor to create a card from another card as a copy. 6) Ability to use the <, >, == and != operators, where < and > only compare the card value and not the suit. 7) Ability to print the card like this: 5 of Hearts (as an example) 8) Ability to use the + and - operators on two cards to produce an integer value (not another card). Assume + and - means add or subtract card values only. 9) Ability to use the = operator for assigning one card to equal another card. 2) Create a deck template class to use with your card class. (You can start with example one on the website). Add a method to shuffle the deck using any algorithm of your choice (it can be any simple algorithm). ## Deliverables The main function should do the following things: 1) Create all 52 cards as in a standard deck of cards and insert them into the deck one by one. 2) Shuffle the deck. 3) Ask the user to pick any card 4) Randomly pick 5 cards. 5) If the user's card is among the 5 cards picked, they win. 6) If not, print the 5 cards. ## Platform Note: For all classes create a header file, a cpp file, and and driver file. Important: You should submit your source files and executable file. All files should be able to compile on the "Apache server" without any error. ## Deadline information Program must be finished and received by 1:30pm on Monday, September 9th.
Project ID: 2869109

About the project

18 proposals
Remote project
Active 22 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
See private message.
$12 USD in 14 days
5.0 (47 reviews)
4.5
4.5
18 freelancers are bidding on average $17 USD for this job
User Avatar
See private message.
$25.50 USD in 14 days
5.0 (137 reviews)
7.0
7.0
User Avatar
See private message.
$29.75 USD in 14 days
5.0 (125 reviews)
5.9
5.9
User Avatar
See private message.
$21.25 USD in 14 days
4.4 (72 reviews)
5.5
5.5
User Avatar
See private message.
$15.30 USD in 14 days
5.0 (78 reviews)
5.2
5.2
User Avatar
See private message.
$21.25 USD in 14 days
5.0 (35 reviews)
5.0
5.0
User Avatar
See private message.
$17 USD in 14 days
4.7 (41 reviews)
4.7
4.7
User Avatar
See private message.
$19.55 USD in 14 days
4.9 (28 reviews)
4.6
4.6
User Avatar
See private message.
$6.80 USD in 14 days
4.8 (62 reviews)
4.2
4.2
User Avatar
See private message.
$5.95 USD in 14 days
4.9 (27 reviews)
3.3
3.3
User Avatar
See private message.
$12.75 USD in 14 days
5.0 (53 reviews)
3.3
3.3
User Avatar
See private message.
$12.75 USD in 14 days
5.0 (2 reviews)
2.9
2.9
User Avatar
See private message.
$25.50 USD in 14 days
5.0 (7 reviews)
2.6
2.6
User Avatar
See private message.
$17 USD in 14 days
4.8 (13 reviews)
2.5
2.5
User Avatar
See private message.
$12.75 USD in 14 days
5.0 (3 reviews)
2.2
2.2
User Avatar
See private message.
$17 USD in 14 days
5.0 (4 reviews)
1.3
1.3
User Avatar
See private message.
$8.50 USD in 14 days
0.0 (0 reviews)
0.0
0.0
User Avatar
See private message.
$17 USD in 14 days
0.0 (0 reviews)
0.0
0.0

About the client

Flag of UNITED STATES
United States
5.0
8
Member since Jun 28, 2002

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.