Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I Need a help in Writing a Matlab script (program) to assist with calculating the cost for customer orders General Description: A materials supply company
I Need a help in Writing a Matlab script (program) to assist with calculating the cost for customer orders
General Description: A materials supply company offers bars of various lengths and metals for saleto manufacturing companies. Write a Matlab script (program) to assist with calculating the cost for customer orders. The supply company offers bars in three metals: Aluminum, Brass, Copper and Steel. They offer bars in custom lengths. Specifications: First, the program should clear the screen and display a list of metals, with a number for each, and ask the user which metal to use. If the user enters an invalid selection, assume the metal is Steel. Next, the program should ask the user to enter the bar size, in feet, and the number of bars ordered. Next, the program decides on the cost per foot and weight per foot, based on the metal chosen. The values are: Metal Cost per foot Weight: pounds per foot Aluminum $2.51 0.30 1.0 $1.49 Brass $1.78 Copper 0.85 $1.22 Steel 0.75 Here, it should also decide on the metal name to be printed in the report The program then calculates the total length of all bars ordered, the total cost of the bars and the total weight. It then calculates the shipping charge as $0.25/pound, and add this to the total cost of the bars to get the total price. Round the total price to two digits past the decimal point. The program prints a report with the calculated values as shown in the examples below Finally, the user is asked if they want to process another order (Yor N). If the answer is Y or y, the entire above process should be repeated. If any other answer is given, the program ends. As the program ends, it should print the total dollar cost of bars sold for the day (not including shipping) This should NOT be printed after each order is completed...only after the user chooses to NOT process another order. (see below)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