Answered step by step
Verified Expert Solution
Question
00
1 Approved Answer
QUESTION Write a program that has a class HOUSE. The house has an owner string, an location string, and rooms int to store the number
QUESTION Write a program that has a class HOUSE. The house has an owner "string", an location "string", and rooms "int" to store the number of rooms in the house. The class has the following methods: Set and get methods for each attribute. - Print method: prints the information "attributes" of the house. Area method: calculates and returns the area of the house. Area = number of rooms 9 In the main, do the following: Define two house objects with their data. Print the information of the two objects (with the area). - Print which house is larger by comparing the two areas of the houses. YE
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started