In C++ write an application that calculates total retail values for 5 different shoes entered by the user.
Shoe 1 $15.50
Shoe 2 $27.30
Shoe 3 $34.50
Shoe 4 $42.11
Shoe 5 $54.25
Application must read shoe number and quantity sold for each
transaction stdin, compute the total value of that sale, and add
the value of that sale to a grand total for that shoe. After all
data has been entered, display the total value of each of the five
shoe items. Must have driver and a class, must use a switch
structure to which shoes sales to update, must use a sentinel
controlled loop to determine when the program should stop looping
and display result.
Data members
Product price
Total sales for product(in dollars)
Member Functions
One 1 argument constructor(representing the shoe price), set the
value of the data member using this argument. Getters and setters
for data member, and updateTotalSales method(uses one parameter
representing quantity sold and does not return a value) . must use
getter and setter methods to access the fields do not access them
directly. It computes the total value of the current sale by
multiplying the argument passed by the shoess price. It updates the
shoes total Sales data member by adding the value calculated in the
previous step to the shoes existing totalSales. Must use getter and
setter functions. Do not access the data members directly.
Main function
Instantiate 5 separate objects of the class Shoe, passing the
appropriate argument to each constructor. The Shoe class
constructor requires the price of that instance of the shoe. The
prices can be hard coded numbers.
Using Sentinel controlled loop
1. Read the shoe number and the quantity sold for one
transaction.
2. Use a switch statement to determine which Shoe
objects sales to update.
3. Call the appropriate Shoe objects updateTotalSales
function.
4. Continue loop until user enters 0 for the shoe
number.
5. After the loop is complete display each shoe objects
total sales, including the dollar sign, two decimal places with a
field width of 10.
Sample run
Shoe number: 2
Quantity sold: 4
Shoe number: 1
Quantity sold: 3
Shoe Number: 5
Quantity sold: 2
Shoe number: 1
Quantity sold: 2
Shoe number: 5
Quantity sold: 3
Shoe Number: 4
Quantity sold: 2
Shoe Number: 0
Total Sales
Shoe 1 : $77.50
Shoe 2: $109.20
Shoe 3: $0
Shoe 4: $84.22
Shoe 5: $271.25
In: Computer Science
In: Psychology
In: Physics
African Americans, Hispanics, American Indians and people from India, Bangladesh, Sri Lanka and Pakistan have a higher risk of Chronic Kidney Disease. Why is this? What are the effects of Chronic Kidney Disease on the quality of life of an individual?
In: Anatomy and Physiology
Two articles describing firms’ use of a cooperative strategy: one where trust is being used as a strategic asset and another where contracts and monitoring are being emphasized. What are the differences between the managerial approaches being used in the two companies? Which of the cooperative strategies has the highest probability of being successful? Why?
- No TALK ABOUT: Apple, McDonald's, Whole Food Market, Walmart or T-Mobile.
nor Plagiarism!!
Please
In: Operations Management
A 2.50 kg block on a horizontal floor is attached to a horizontal spring that is initially compressed 0.0300 m . The spring has force constant 835 N/m . The coefficient of kinetic friction between the floor and the block is 0.41 . The block and spring are released from rest and the block slides along the floor. Part A What is the speed of the block when it has moved a distance of 0.0130 m from its initial position? (At this point the spring is compressed 0.0170 m .)
In: Physics
IN JAVA LANGUAGE
Linked List-Based Stack Implementation
Implement Stack using a Linked List
Instead of using an array, as the StackLab did, here you will use a Linked List from your language's library. Implement all the methods of Stack : push(), pop(), size(), printStackDown(), etc, using calls to the linked list methods that correspond to the actions need. In the array implementation, you wrote code to manipulate the array. For this linked list implementation, methods already exist.
Before the underlying implementation of stack was array, now the underlying implementation of stack will be Linked list.
In: Computer Science
Implement techniques to increase customer’s product exposure?
CASE STUDY SITUATION
You are the vice president of development for BULLET, the second largest discount retailer in the nation. The senior VP has asked you to analyze a new sales venture and determine how to build a clientele foe the new venture and for traditional BULLET stores.
There are close to 2000 BULLET stores across the country, most anchoring strip malls or outdoor shopping centers. BULLET stores feature typical grocery store items along with pharmacies, apparel, home décor, books, toys, electronics, seasonal items and health and beauty sections. BULLET’S biggest competitor is BOX MART, the leading discount retailer. BULLET does not come close to the number of store locations nor the revenue that BOX MART produces each year. Aside from similar store layouts and product offerings, there are notable differences between the two discount retailers.
Although product offerings are similar, BULLET has a much different image than BOX MART. BULLET is perceived to be better organized, with a more streamlined store layout. They are also more in touch with fashion trends and home décor. BULLET also markets higher quality house brands in all departments, most notably in its food and beverage departments. BULLET offers a wide variety of fresh, ready-to-eat meals that beat BOX MART’S offerings in customer ratings each year.
Executives at BULLET have decided to test market a concept for a BULLET branded convenience store. The BULLET convenience store will be located away form BULLET stores and will offer fuel and the loyal BULLET customer, and also new clientele who does not usually shop at BULLET stores. They are also hoping to attract the BOX MART customer.
YOUR CHALLENGE
The senior VP wants you to determine how a BULLET C-store can feel like a BULLET store, rather than a typical convenience store. You are to suggest techniques tha can expose BULLET C-store customers to BULLET retail store products, ideally resulting in a larger clientele for BULLET retail stores.
In addition, you need to plan the product mix the BULLET C-stores; what typical convenience store products should be sold and what other products should be sold to keep up with BULLET’S well-regarded image? Are there store services that should be offered or not?
In: Operations Management
A 110cm3 box contains helium at a pressure of 2.00atm and a temperature of 100?C. It is placed in thermal contact with a 210cm3 box containing argon at a pressure of 4.00atm and a temperature of 420?C.
What is the initial thermal energy of each gas?
What is the final thermal energy of each gas?
How much heat energy is transferred, and in which direction?
What is the final temperature?
What is the final pressure in each box?
In: Physics
Calculate the pH of the solution that results from each of the following mixtures
A.) 150.0mL of 0.23M HF with 225.0mL of 0.32M NaF
B.) 185.0mL of 0.12M C2H5NH2 with 285.0mL of 0.22M C2H5NH3Cl
In: Chemistry
Julie throws a ball to her friend Sarah. The ball leaves Julie's hand a distance 1.5 meters above the ground with an initial speed of 24 m/s at an angle 35 degrees; with respect to the horizontal. Sarah catches the ball 1.5 meters above the ground.
g = 9.81m / s^2
(1) After catching the ball, Sarah throws it back to Julie. The ball leaves Sarah's hand a distance 1.5 meters above the ground, and is moving with a speed of 23 m/s when it reaches a maximum height of 13 m above the ground.
What is the speed of the ball when it leaves Sarah's hand?
How high above the ground will the ball be when it gets to Julie? (note, the ball may go over Julie's head.)
(2) After catching the ball, Sarah throws it back to Julie. However, Sarah throws it too hard so it is over Julie's head when it reaches Julie's horizontal position. Assume the ball leaves Sarah's hand a distance 1.5 meters above the ground, reaches a maximum height of 13 m above the ground, and takes 2.399 s to get directly over Julie's head.
What is the speed of the ball when it leaves Sarah's hand?
How high above the ground will the ball be when it gets to Julie?
In: Physics
IN JAVA LANGUAGE
Linked List-Based Queue Implementation
Implement Queue using a Linked List.
Instead of using an array, as the QueueLab did, here you will use a Linked List from your language's library. Implement all the methods of Stack : enqueue(), dequeue(), size(), printQueue(), etc, using calls to the linked list methods that correspond to the actions need. In the array implementation, you wrote code to manipulate the array. For this linked list implementation, methods already exist.
Before the underlying implementation of queue was array, now the underlying implementation of queue will be Linked list.
In: Computer Science
In: Psychology
Non-Value-Added Activities: Non-Value-Added Cost
Thayne Company has 28 clerks that work in its Accounts Payable Department. A study revealed the following activities and the relative time demanded by each activity:
| Activities | Percentage of Clerical Time |
| Comparing purchase orders and receiving orders and invoices | 10% |
| Resolving discrepancies among the three documents | 73 |
| Preparing checks for suppliers | 7 |
| Making journal entries and mailing checks | 10 |
| The average salary of a clerk is $40,100. |
Required:
Classify the four activities as value-added or non-value-added, and calculate the clerical cost of each activity.
| Comparing documents | $fill in the blank 2 | |
| Resolving discrepancies | $fill in the blank 4 | |
| Preparing checks | $fill in the blank 6 | |
| Mailing checks | $fill in the blank 8 |
In: Accounting
In: Operations Management