The Weight class
posted by: Ms. Martin
15 February 2011
No Comment
You will implement a class to represent weights in pounds and ounces. Your class will have two fields: pounds and ounces. Recall that there are 16 ounces in a pound. Weight objects should never keep track of more than 15 ounces, they should convert the value to pounds instead. Weights can be printed (ex: 1lb 4oz or 3oz or 7lbs 3oz).
Your class will implement the Comparable interface. Write a client that creates several weights, puts them in an ArrayList, then sorts them.





