The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | Jul 2017 |
| Last Sign in: | 314 Weeks Ago |
| Questions Answered: | 15833 |
| Tutorials Posted: | 15827 |
MBA,PHD, Juris Doctor
Strayer,Devery,Harvard University
Mar-1995 - Mar-2002
Manager Planning
WalMart
Mar-2001 - Feb-2009
lab is attached. please send back in word doc with a screen shot showing it works, also should be written in c++. if you have any questions please ask and thanks in advance! and will tip good since it it is on short notice!!!
Â
|
Â
CIS170C Week 6 Lab Instructions
Â
Lab 6 of 7: Menu-Driven Application
Â
Lab Overview—Scenario/Summary
Â
You will code, build, and execute a Retail Item class that holds data about an item in a retail store.You will utilize classes in the design of this program.
Learning outcomes:
Â
Â
Deliverables
|
Section |
Deliverable |
Points |
|
Lab 6 |
Step 5: Program Listing and Output |
40 |
|
All Steps |
Total |
Â
Lab Steps
Â
Preparation:
If you are using the Citrix remote lab, follow the login instructions located on the lab area in Course Home.
Â
Locate the Visual Studio icon and launch the application.
Â
|
Part A: Password Program |
|
Step 1: Requirements |
|
Write a windows console application that holds data about an item in a retail store. Your class should be named RetailItem and should hold data about an item in a retail store. The class will have the following member variables. description—string holding the description of the item unitsOnHand—int that holds the number of units in inventory price—double that holds the price of the item You will need two constructors, one that will accept arguments for each member variable and one that will assign default values. You will also need to write mutator functions and accessor functions. Once you write the class, write a separate program that creates three RetailItem objects. The first one should use the default values, and the other two should have values assigned upon creation. The user should input the variables (testing for the units on hand and price greater than 0). Then the program should display all three RetailItems. Finally, the program should tally the inventory for all three items and display it.  Welcome to the Retail store! Price must be greater than 0. Please enter the price for item 1: 33. Inventory must be greater than 0. Please enter the units on hand for item 1: 10. Please enter the description for item 1: shirt.   Display all items Description: shirt Units on hand: 10 Price: $33.00  Description: Jeans Units on hand: 40 Price: $34.95  Description: Long sleeve shirt Units on hand: 20 Price: $24.95    Display the total inventory. The total inventory is 70. Press any key to continue.       |
|
Step 2: Processing Logic |
|
 Using the pseudocode below, write the code that will meet the requirements.  Create a mainprogram. Create three RetailItem objects.       Ask user for price for item1 looping until value is greater than 0.                   Ask user for unitsOnHand for item2 looping until value is greater than 0.                   Ask user for description for item 1.                    Display all items. Add up total inventory, and display total inventory.  Create a RetailItem class. Implement all member functions. Create a RetailItem.h.       Private member variables should be description, unitsOnHand, and price.         Public member functions include both constructors, mutator, and accessor functions for all three variables. .  |
|
Step 3: Create a New Project |
|
Create a new project and name it LAB6. Write your code using the processing logic in Step 2. Make sure you save your program. Â |
|
Step 4: Compile and Execute |
|
a)Â Â Â Â Compile your program and eliminate all syntax errors. Â b)Â Â Â Build your program, and verify the results of the program. Make corrections to the program logic if necessary until the results of the program execution are what you expect. Â |
|
Step 5: Print Screenshots and Program |
|
1.    Capture a screen print of your output.(Do a PRINT SCREEN and paste into an MS Word document.) 2.    Copy your code and paste it into the same MS Word document that contains the screen print of your output. 3.    Save the Word document as Lab06_LastName_FirstInitial.  |
|
END OF LAB |
Â
----------- Â ----------- H-----------ell-----------o S-----------ir/-----------Mad-----------am ----------- Th-----------ank----------- yo-----------u f-----------or -----------you-----------r i-----------nte-----------res-----------t a-----------nd -----------buy-----------ing----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n. -----------Ple-----------ase----------- pi-----------ng -----------me -----------on -----------cha-----------t I----------- am----------- on-----------lin-----------e o-----------r i-----------nbo-----------x m-----------e a----------- me-----------ssa-----------ge -----------I w-----------ill----------- be----------- qu-----------ick-----------ly