Question: JAVA PROGRAM You are required to write programs in java that will sort student records using binary search tree. Your program will read the student
JAVA PROGRAM
You are required to write programs in java that will sort student records using binary search tree. Your program will read the student records from the file Students.txt (provided). Each student record consist of student name, student roll number, address, and GPA and each record read should be stored as an object of Student class. Sort the student records using binary search tree. The student roll number for each student is used a primary key. The sorted student records will need to be saved in the file sortedStudents.txt. The program also able to provide the following sample statistics: Statistics of GPA <= 2.0 5 students > 2.0 5 students
Alvin Chong A211343 No.23#34,Johor 2.0 Raja Kumar A211442 43A #999,Shah Alam 3.5 Suzie Anne A211212 A87 Block C Floor 3,Melaka 4.0 Johnny Marcus A211333 Block F Floor 2 #44 Genting highland 4.0 Kok Meng Ang A211521 56A #88 Kuala Lipis 3.0 Cherry Lynn A211654 #987 Block D Floor 3 Kuala Pilai 2.5 Zeus henry A211143 No99 #6678 Langkawi 1.5 Bowd Jerry A211998 Block M Floor 4 Pulau Pinang 1.0 Lynda Ong A211456 No76A #767 Kota Belud 1.5 Hong Chung A211866 No342A #980Kota Kinabalu 2.0
[Above is Students.txt( please save it as txt first) And this Students.txt can be read from program]
You need to define all the necessary classes and catch all possible exceptions.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
