Java I CS 142 Week 03 Assignment.docx

advertisement
Java I CS 142 Week 03 Assignment
You will write a program to calculate shipping charges.
Weight of package
3 pounds or less
Over 3 pounds up to 8 pounds
Over 8 pounds up to 12 pounds
Over 12 pounds
Rate per 100 miles shipped
$2.65
$5.15
$6.25
$8.50
The shipping charges per 100 miles are not prorated. For example, if a 2.5 pound package is shipped
110 miles, the charge would be $5.30.
Your program should have your name in a comment on the first line of code, and it should display as its
first line of output: “{your name} Shipping company” (using your name, so I can see it when I’m grading).
Your program should ask the user to enter the weight of a package and distance to ship. It should then
display the shipping charges.
The instructions should be clear an easy to understand. The total shipping charges should be labeled
clearly .
Use console I/O for this program (Scanner and System.out.print...), not JOptionPane.
Your class name should be Week03, and the filename must be “Week03.java”
Due, as usual, at high noon on Sunday. 
Scoring will be as follows:
Basic program that works: 90
The program is well indented and commented: +5
Instructions are clear when the program runs, and the output is well labeled: +5
Download