Question: I need help on solving this assignment Review the class called People We will partially implement that class in Java. For this purpose, we will

I need help on solving this assignment

Review the class called "People"

We will partially implement that class in Java. For this purpose, we will consider these attributes on "People" class.

people_id stage_name first_name last_name

[1] Implement a Java class called "People"

[2] You need to have these two methods

toString( ) method -> returns the string representation containing the above 4 attributes

equals( ) method --> two people are equal only when stage_name, first_name, and last_name match between two People

[3] Also, make the "People" class implement "Comparable" interface.

Implement the "compareTo( )" method.

The "stage_name" is ordered lexicographically by the compareTo( ) method.

[4] Implement the main( ) method to create some people objects and test the above three methods

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!