Homework 1 Due 2025-02-09
Student Information:
Your name:
Email: <blackboard/cunyfirst email>
Code: (1 Questions, total 100 pts):
#1 (100 pts):
Step 1:
Please download the bag code. Chapter-1
- Bag.cpp
- Bag.h
- BagInterface.h
- main.cpp
Setup a project in your IDE or on lab machine, so that you are able to run
the code. and see it outputs correctly
Step 2:
In main.cpp you will see this block of code.
grabBag.add(clubs[1]);
grabBag.add(clubs[2]);
grabBag.add(clubs[4]);
grabBag.add(clubs[8]);
grabBag.add(clubs[10]);
grabBag.add(clubs[12]);
(20pts) Please update it to use any cards of your choice. You can use
anything for example club[3], club[11] etc.. as long as the orders are
different.
Once it is updated, please rerun the program and copy output for submission.
Please submit, a modified version of your main.cpp, and the program output
in text format.
Page 1 of 2
For setting up project, we will go over in class, also we can reference the
short demo below
Windows - VisualStudio
https://www.youtube.com/watch?v=_hyN1Sgnoog
Mac - xcode
https://www.youtube.com/watch?v=LvOIp4TUFfE
Page 2 of 2