Question: Please provide the java code. Please don't post the code as pictures. 1 Hall Equality Now we know how to use the equals() method. Now

 Please provide the java code. Please don't post the code aspictures. 1 Hall Equality Now we know how to use the equals()method. Now let's use it in our application to reduce redundancy. Same

Please provide the java code. Please don't post the code as pictures.

1 Hall Equality Now we know how to use the equals() method. Now let's use it in our application to reduce redundancy. Same halls cannot be booked on the same date for two different events. So get the halls booked by two different persons and check whether it is same or not. Use equals method to check all attributes of the hall are equal including booking date. Create Hall class with following private attributes Attributes Datatype name String contact Number String costPerDay Double ownerName String Include appropriate getters and setters Create Default and Parameterized Constructor as Hall(String name, String contact Number, Double costPer Day, String ownerName) for the class. Override equals method that compares all the fields of the class. Create a driver class named Main to test the above class. Input Format Input consist of two sets of hall booking details Refer sample input Output Format Output prints whether the booked halls are same or not Sample Testcases Testcase 1 Input Testcase 1 Output Halls are different Benny 9089078654 1000 Dayal Samir 9789432346 2000 Dev Testcase 2 Input Testcase 2 Output Halls are same Benny 9089078654 1000 Dayal Benny 9089978654 1000 Dayal

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!