Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

dear prof i wish u will hell and show the steps clearly and thank you so much . This exercise is intended for students to:

image text in transcribed

image text in transcribed

dear prof i wish u will hell and show the steps clearly and thank you so much .

This exercise is intended for students to: 1. apply file processing techniques to solve a related problem 2. classify the scenario in applying the file processing technique LAB EXERCISE 1 Tasks: T-Shirt4U is an online business company that sells muslimah t-shirt in Malaysia. The company has appointed you to develop a sale analysis system. System is intended to facilitate the manager to analyze sales record. The sales record in given to you with the information as shown in the input file named sales.txt as in Figure 1. The price o the muslimah t-shirt is RM50.00/piece. Customer D Number of t-shirt Delivery Destination C1001 5 C1002 10 C1003 13 C1004 20 C1005 30 SEMENANJUNG SEMENANJUNG SEMENANJUNG SABAH SARAWAK Figure 1: sales.txt file The company will give 5% discount if the customer buys more than 5 pieces, 10% discount for more than 10 pieces, 20% discount for more than 15 pieces and 30% for more than 20 pieces. The t-shirts will be delivered by using courier all over Malaysia. For SEMENANJUNG, the company will charge RM3.00 per piece and for SABAH/SARAWAK will be charged RM8.00 per piece. After all the process, the system will print out the processed information in an output file. Figure 2 is the example of output file with the processed information. SALES RECORD Customer ID T-Shirt Discount Total Price Destination Postage_Fare Total Fare C1001 C1002 C1003 C1004 C1005 5 10 13 20 30 0.00 25.00 65.00 200.00 450.00 250.00 475.00 585.00 800.00 1050.00 SEMENANJUNG SEMENANJUNG SEMENANJUNG SABAH SARAWAK 15.00 30.00 39.00 160.00 240.00 265.00 505.00 624.00 960.00 1290.00 The t-shirts will be delivered by using courier all over Malaysia. For SEMENANJUNG, the company will charge RM3.00 per piece and for SABAH/SARAWAK will be charged RM8.00 per piece. After all the process, the system will print out the processed information in an output file. Figure 2 is the example of output file with the processed information SALES RECORD Customer ID T-Shirt Discount Total Price Destination Postage_Fare Total Fare 5 10 C1001 C1002 C1003 C1004 C1005 13 20 30 0.00 25.00 65.00 200.00 450.00 250.00 475.00 585.00 800.00 1050.00 SEMENANJUNG SEMENANJUNG SEMENANJUNG SABAH SARAWAK 15.00 30.00 39.00 160.00 240.00 265.00 505.00 624.00 960.00 1290.00 - - - - Total Sales: 3644.00 Figure 2: salestatistic.txt file 30 Your system would have a few functions such as main, calculate_discount, calculate postage and etc. a. Based on the problems and user requirement given construct a flowchart or pseudocode to indicate the flow of sale analysis system. b. Translate the flowchart or pseudocode into full free error coding Hints functions, 2-D Array, File

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

MySQL Crash Course A Hands On Introduction To Database Development

Authors: Rick Silva

1st Edition

1718503008, 978-1718503007

More Books

Students also viewed these Databases questions

Question

=+ How well do you think you could do your job?

Answered: 1 week ago