Computer Science 252
Problem Solving with Java
Spring 2016, The College of Saint Rose
Agenda
Extend the ShirtAndPants example to include a third type of article of clothing. Maybe it's warm and you need shorts. Or it's cold and you need a hat. Your new class should be an implementation of the Laundry interface. The only requirements are that your new object consists of at least 3 graphics primitives, at least 1 of which can be colored randomly, and that it can reasonably implement all of the methods required by the Laundry interface. Also modify the ShirtsAndPants class to create objects of your new type with equal probability as the existing TShirt and Pants objects. You should not need to make any other changes to the ShirtAndPants class.
Please demonstrate your program or submit only the Java file for the new class you create that implements the Laundry interface by email before you leave class. Email submissions should use a meaningful subject line, clearly indicating the course number and assignment name.
No New Lecture Assignment
You have a lab to wrap up and a take home lab practical exam to worry about.
Terminology
Examples
Links