Question: This question is of Data Structure.Write the code in java language.Do it according to given instructions. In this assignment, you are required to complete the

This question is of Data Structure.Write the code in java language.Do it according to given instructions.

This question is of Data Structure.Write the code in java language.Do it

In this assignment, you are required to complete the steps given below. Question 1: Implement the following hierarchy of classes given below. Person Name: String Age: int Id: int Constructors Setters Getters ToString Student Programmer Semesterint Department. String Teacher Subject Speciality: String Salary: double Typing Speed (WPM): int Constructors Setters Getters ToString Constructors Setters Getters ToString Constructors Setters Getters ToString Question 2: Write two other classes SortByNameAscending and SortByNameDescending which implements the Comparator and implements its overridden method so that it sorts the arrayStudent, arrayTeacher, array Programmer in both Descending and Ascending order by Name. 2/3 BS-CS/SE Program CS-242 GIFT University Question 3: Now Write another class LoadAndSortData with the main method and do the following tasks. Create an array list of type ArrayList Create an array list of type ArrayList Create an array list of type ArrayList Create objects of Student, Teacher and Programmer class Add each object into its respective ArrayList that you created above. Sort all the ArrayLists (array Student, arrayTeacher, array Programmer) in ascending order by the SortByNameAscending class and then print the list. Sort all the ArrayLists (array Student, arrayTeacher, array Programer) in descending order by the SortByNameDescending class and then print the list

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!