-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathManager.java
36 lines (33 loc) · 1.02 KB
/
Manager.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import java.io.*;
import java.util.*;
class Manager
{
public static void main(String args[])throws IOException
{
Scanner sc = new Scanner(System.in);
int choice, flag = 0;
do
{
System.out.println("Enter 1 for admin, 2 for student");
choice = sc.nextInt();
switch(choice)
{
case 1 :
Admin admin = new Admin();
admin.adminpanel();
System.out.println("Goodbye! Admin");
break;
case 2 :
StudentPortal student = new StudentPortal();
student.studentpanel();
System.out.println("Goodbye! Student");
break;
default:
System.out.println("Invalid Request");
}
System.out.println("Do you want to continue?");
System.out.println("Press 0 to exit and 1 to continue");
flag = sc.nextInt();
}while(flag == 1);
}
}