(Financial application: find the profit-per-item) You have just started a new stationary shop. Your profit-per-item depends on the total quantity of item sold. The scheme shown below is used to determine the total profit: Quantity Profit-per-item 0-1000 $1 1001-5000 $2 5001 and above $5 Note that this is a graduated profit. The profit for selling up to 1000 items is $1, for next 4000 items is $2 and beyond that is $5. If the total quantity of item sold is 10000, the profit is 1000 * $1 + 4000 * $2 + 5000 * $5 = $34000. Your goal is to make $50,000 a year. Write a program that uses a do-while loop to find out the minimum quantity of item you have to sell in order to make $50,000.

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter12: Points, Classes, Virtual Functions And Abstract Classes
Section: Chapter Questions
Problem 2SA
icon
Related questions
Question
(Financial application: find the profit-per-item) You have just started a new
stationary shop. Your profit-per-item depends on the total quantity of item sold.
The scheme shown below is used to determine the total profit:
Quantity
Profit-per-item
0-1000
$1
1001-5000
$2
5001 and above
$5
Note that this is a graduated profit. The profit for selling up to 1000 items is $1,
for next 4000 items is $2 and beyond that is $5. If the total quantity of item sold
is 10000, the profit is 1000 * $1 + 4000 * $2 + 5000 * $5 = $34000.
Your goal is to make $50,000 a year. Write a program that uses a do-while
loop to find out the minimum quantity of item you have to sell in order to make
$50,000.
Transcribed Image Text:(Financial application: find the profit-per-item) You have just started a new stationary shop. Your profit-per-item depends on the total quantity of item sold. The scheme shown below is used to determine the total profit: Quantity Profit-per-item 0-1000 $1 1001-5000 $2 5001 and above $5 Note that this is a graduated profit. The profit for selling up to 1000 items is $1, for next 4000 items is $2 and beyond that is $5. If the total quantity of item sold is 10000, the profit is 1000 * $1 + 4000 * $2 + 5000 * $5 = $34000. Your goal is to make $50,000 a year. Write a program that uses a do-while loop to find out the minimum quantity of item you have to sell in order to make $50,000.
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,