Question: Create a Building class and two subclasses, House and School. The Building class contains fields for square footage and stories. The House class contains additional
Create a Building class and two subclasses, House and School. The Building class contains fields for square footage and stories. The House class contains additional fields for number of bedrooms and baths. The School class contains additional fields for number of classrooms and grade level (for example, elementary or junior high). All the classes contain appropriate get and set methods. Place the Building, House, and School classes in a package named com.course.buildings. Create an application that declares objects of each type and uses the package. Save the necessary files as Building.java, House.java, School.java, and CreateBuildings.java.
Step by Step Solution
3.48 Rating (168 Votes )
There are 3 Steps involved in it
Building package comcoursebuildings public class Building protected int sqFeet protected int stories ... View full answer
Get step-by-step solutions from verified subject matter experts
