Professional Documents
Culture Documents
Description
Your task is to create a Student Record Management System using Java. This system will allow users to
manage student information including their names, ages, and grades. The system should provide
functionality to add new students, view existing student records, update student information, and delete
student records
Import java.io.*;
Import java.util.ArrayList;
Import java.util.Scanner;
Class Student implements Serializable {// class named “Student” to represent individual student record.
This.name = name;
This.age = age;
This.grade = grade;
Return name;
Return age;
Return grade;
@Override
Public void addStudent(String name, int age, double grade) {//add a new newstudentrecord
If (student.getName().equalsIgnoreCase(name)) {
Return student;
Return null;
If (student != null) {
} else {
Students.remove(student);
System.out.println(“Student deleted.”);
} else {
If (students.isEmpty()) {
} else {
System.out.println(student.toString());
Int choice;
Do {
System.out.println(“\nStudent Record Management System Menu:”);
System.out.println(“6. Exit”);
Try {
Choice = scanner.nextInt();
Switch (choice) {
Case 1:
break;
case 2:
Name = scanner.nextLine();
If (student != null) {
System.out.println(student.toString());
} else {
Break;
Case 3:
Name = scanner.nextLine();
Age = scanner.nextInt();
Grade = scanner.nextDouble();
break;
case 4:
Name = scanner.nextLine();
recordManager.deleteStudent(name);
break;
case 5:
recordManager.viewAllStudents();
break;
case 6:
Oos.writeObject(recordManager);
} catch (IOException e) {
System.out.println(“Goodbye!”);
Break;
Default:
} catch (InputMismatchException e) {
Scanner.close();