Question
Programming in Java: You will need to create a program for the UD bookstore to help with taking orders for UD sweatshirts. The program should
Programming in Java:
You will need to create a program for the UD bookstore to help with taking orders for UD sweatshirts. The program should allow the user to select the size of sweatshirt, the type (pull-over or zipper front), and color. It should allow for one customer to order multiple sweatshirts, calculate the price of each item, write it to a file, calculate the total for the order and write it to the file, and then display the total amount of the order on the screen. Use the following chart for prices:
Sizes
Item | Price |
Small | $9.95 |
Medium | $10.25 |
Large | $11.75 |
X-Large | $12.00 |
Types
Item | Price |
Pull-over | No extra charge |
Zippered | $1.50 |
Colors
Item | Price |
White | No extra charge |
Blue | $1.25 |
Blue & White | $2.50 |
It should display the total for each person; and write an order to a file, named receipt.txt, for them as follows:
Customer: Ann Mauss
Size: Medium $10.25
Type: Pull-over $ 0.00
Color: Blue $ 1.25
Sub-Total $11.50
Size: Large $11.75
Type: Zipper $ 1.50
Color: Blue & White $ 2.50
Sub-Total $15.75
Sub-Total for order: $27.25
Tax: $ 1.91
Total: $29.16
Requirements
You should create a class called Sweatshirt that contains methods that will manipulate a sweatshirt.
You should use methods appropriately
You must have a least one method that returns a value
You must have at least one method that takes a parameter.
You must have at least one method that is a void function
You should include all data validation where necessary.
You should include at least one selection structure.
You should include at least one repetition structure, excluding data validation.
You will need to use a least one constant variable type.
Use appropriate data types
Use appropriate comments.
Written code should be formatted appropriately, i.e. Indent!
Open and close files appropriately.
You should match the formatting of the report to the example.
Assumptions
There is sales tax to apply. It is 7% on the total of the order.
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