Java Code
Java Code
ArrayList;
import java.util.Scanner;
class Main {
employees.add(newEmployee);
}
showMenu();
}
System.out.print("4) EXPERIENCE:-->");
newEmployee.exp = sc.nextInt();
employees.add(newEmployee);
showMenu();
}
showMenu();
}
System.out.println("AVAILABLE OPTIONS:\n");
System.out.print("* BUILD TABLE -----> (1)\n");
System.out.print("* INSERT NEW RECORD -----> (2)\n");
System.out.print("* DELETE RECORD -----> (3)\n");
System.out.print("* SEARCH A NEW RECORD -----> (4)\n");
System.out.print("* EXIT -----> (5)\n");
if (option == 1) {
build();
} else if (option == 2) {
insert();
} else if (option == 3) {
deleteRecord();
} else if (option == 4) {
searchRecord();
} else if (option == 5) {
return;
} else {
System.out.println("Expected Options are 1/2/3/4/5");
showMenu();
}
}