Created
April 9, 2012 06:07
-
-
Save ChrisLundquist/2341891 to your computer and use it in GitHub Desktop.
package.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Require Package | |
| public class Assignment1 { | |
| public static void main(String[] argv){ | |
| // get package count | |
| // packages = array of packages | |
| // cost = 0; | |
| // for package count times | |
| // get h,l,w,weight,method | |
| // packages[i] = new Package(stuff); | |
| // price += packages[i].getPrice() | |
| // Print whatever | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class Package { | |
| public Package(); | |
| public Package(float height, float length, float width, float weight); | |
| public Package setHeight(float height); | |
| public Package setLength(float length); | |
| public Package setWidth(float width); | |
| public Package setWeight(float weight); | |
| public float setShippingMethodToLand(); | |
| public float setShippingMethodToAir(); | |
| public float getVolume(); | |
| public float getPrice(); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment