Question: MyJava Coffee Outlet decided to give discounts to volume buyers. The discount is based on the following table: Order Volume Discount 2 25 bags

MyJava Coffee Outlet decided to give discounts to volume buyers. The discount 

MyJava Coffee Outlet decided to give discounts to volume buyers. The discount is based on the following table: Order Volume Discount 2 25 bags 2 50 bags 2 100 bags 2 150 bags 5% of total price 10% of total price 15% of total price 20% of total price Each bag of beans costs $5.50. Write an application that accepts the number of bags ordered and prints out the total cost of the order in the following style: Sample Runl: Enter the Number of bags ordered: 173 The total cost of the order: 951.50 Your Discount is 20% which is $ 190.30 Your final charge is: $ 761.20 Sample Run2: Enter the Number of bags ordered: -120 Invalid Input, Enter a positive value for number bags !

Step by Step Solution

3.48 Rating (171 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

The code is as follows import javautil public class MyClass ... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Document Format (2 attachments)

PDF file Icon

635f36f493741_231682.pdf

180 KBs PDF File

Word file Icon

635f36f493741_231682.docx

120 KBs Word File

Students Have Also Explored These Related Programming Questions!