subject

Write a Java application that includes the following: Sophie, Sally and Jack's financing for their real estate development business is going well. The next step is to create a prototype Subdivision class.
Write a class Subdivision
A Subdivision has only one instance variable, an ArrayList of House elements
Subdivision has a single, no argument constructor.
Accessors
House get(int position) returns the House occupying the given position in the Subdivision. The first house added to the Subdivision is position 0, the next house added is position 1, etc.
ArrayList < House > list() returns the list of houses in this subdivision. The houses in the returned list are in the same order as they were added to the subdivision.
ArrayList < House > listByArea(double floor, double ceiling) returns the list of houses whose total area is greater than or equal to floor, and less than or equal to ceiling. The houses in the returned list are in the same order as they were added to the subdivision. If there are no such houses in the subdivision, an empty list is returned.
ArrayList < House > listByBedrooms(int floor, int ceiling) returns the list of houses that have greater than or equal to floor bedrooms, and less than or equal to ceiling bedrooms. The houses in the returned list are in the same order as they were added to the subdivision. If there are no such houses in the subdivision, an empty list is returned.
int size() returns the number of houses in the Subdivision
String toString() returns a String representation of the Subdivision
Mutators
boolean add(House houseToAdd) adds a House to the Subdivision. add returns true if the House was added successfully, false otherwise.
Test Class
Write a class Phase1 that has only a main method. Phase1 is a console program that asks the user for the number of houses to be added to a Subdivision. For each House, the program asks the user for that House's information and adds it to the Subdivision . When all the houses have been entered, it prints the size of the Subdivision , and the contents of Subdivision ordered by position. The program asks the user for floor and ceiling values for total area, and displays the houses whose total area is between or equal to those values. It similarly asks the user for floor and ceiling values for the number of bedrooms, and displays the houses whose number of bedrooms is between the floor and ceiling (inclusive).
Grading Elements
Subdivision has a single instance variable of type ArrayList
Subdivision has a single no argument constructor
All methods return the designated type and have correct signatures
All methods return the correct values
Returned lists have the proper order of House elements
Accessors do not change the state of the Subdivision (i. e., they do not change the instance variable)
add places Houses into the Subdivision at the correct position
Phase1 provides the specified operation to test Subdivision

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 02:30
The can be used to paste text in any order
Answers: 1
question
Computers and Technology, 22.06.2019 07:30
Jasper and samantha are in a robotics competition. the guidelines state that the robots should be able to move a 10-gram weight at least 2 meters and turn in a circle. jasper and samantha have already built the robot. which step of the design process should they follow next to decide whether their robot meets the minimum criteria for the competition?
Answers: 1
question
Computers and Technology, 23.06.2019 02:30
How to launch an app: steps to be successful? launching an app is a great idea, but it’s not that easy as we supposed to think. the majority of mobile applications don’t generate revenue because companies aren’t ready to be competitive. referring to our experience in successfully building and launching apps we hope to you omit these difficulties. we are going to talk about ideas, marketing, testing your product, its development, distribution and support. you will learn 8 product launch stages to succeed.
Answers: 1
question
Computers and Technology, 23.06.2019 04:00
Write a method that takes in an array of point2d objects, and then analyzes the dataset to find points that are close together. be sure to review the point2d api. in your method, if the distance between any pair of points is less than 10, display the distance and the (x,y)s of each point. for example, "the distance between (3,5) and (8,9) is 6.40312." the complete api for the point2d adt may be viewed at ~pf/sedgewick-wayne/algs4/documentation/point2d.html (links to an external site.)links to an external site.. try to write your program directly from the api - do not review the adt's source code.
Answers: 1
You know the right answer?
Write a Java application that includes the following: Sophie, Sally and Jack's financing for their...
Questions
question
Mathematics, 12.12.2020 16:20
question
Mathematics, 12.12.2020 16:20
question
Mathematics, 12.12.2020 16:20
question
Mathematics, 12.12.2020 16:20
question
Chemistry, 12.12.2020 16:20
question
Social Studies, 12.12.2020 16:20
question
Mathematics, 12.12.2020 16:20
question
Business, 12.12.2020 16:20
question
Health, 12.12.2020 16:20
question
Mathematics, 12.12.2020 16:20
Questions on the website: 13722362