Question
ABC Company is dealing with supplying of different types of cements (Twiga, Simba, Dangote etc.). The Company acquires cements from wholesale distributors/companies and supplies to
- ABC Company is dealing with supplying of different types of cements (Twiga, Simba, Dangote etc.). The Company acquires cements from wholesale distributors/companies and supplies to its customers (individuals/companies). In each year, the company needs to know the quantity, tax and profit for each cement type supplied to its prospective customers.
It requires a computer program that keeps record and gives report on the purchasing and selling costs of individual 50kg cement bags and their corresponding quantities supplied per year e.g. 2019. In addition, the program should report the tax paid and the net profit made for individual cement types supplied to its customers in that year.
- Tax payments is done based on the following conditions:
(i) If the quantity supplied is below 1,500 cement bags, the tax is 15% of sales.
(ii) If the quantity supplied did not exceed 3,000 cement bags, the tax is 20% of sales
otherwise the tax is 25%.
You are required to:
(a) Conduct problem analysis and design.
(b) Write algorithms of:
(i) The function to calculate tax.
(ii) The function to calculate profit.
(c) Explain how you are going to format and display your final output as shown in
the sample report for a year 2019?
(d) Write the main program which calls two functions in part (b).
- Display your output in the following format below and use the given sample data for testing
as shown in the report for a year 2019
REPORT FOR YEAR 2019
SN | CEMENT TYPE | PURCHASING PRICE/BAG(USD) | SELLING PRICE/BAG(USD) | QUANTITY SOLD | TAX | PROFIT |
1 | Twiga | 8 | 12 | 1,500 | XXXXX | YYYYY |
2 | Dangote | 7 | 10 | 2,500 | AAAA | BBBB |
- Capture and paste a screenshot of your running program (C++) that uses sample input data given in part (3) and displays a formatted report for a year 2019 as shown in part (3).
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started