static void Main(string[] args) { int choice; Student std = new Student(); while (true) { Console.Clear(); Console.WriteLine("----------------------------------------------------------"); Console.WriteLine(" VP Assignment "); Console.WriteLine("----------------------------------------------------------"); Console.WriteLine("Press one of the Following: "); Console.WriteLine("\t\t1. For Add Record"); Console.WriteLine("\t\t2. For Search Record"); Console.WriteLine("\t\t3. For Delete Record"); Console.WriteLine("\t\t4. For Top 3 Student"); Console.WriteLine("\t\t5. For Mark Attendence"); Console.WriteLine("\t\t6. For Veiw Attendence"); Console.WriteLine("\t\t7. For Exit"); Console.Write(" Your Choice: "); choice = Convert.ToInt32(Console.ReadLine()); std.reading(); Console.Clear(); switch (choice) { case 1: { std.studentInput(std); break; } case 2: { std.studentSearch(); break; } case 3: { std.deleteRecord(); break; } case 4: { std.topStudent(); break; } case 5: { std.markAttendance(); break; } case 6: { std.veiwAttendance(); break; } case 7: { System.Environment.Exit(1); break; } default: { Console.WriteLine("\n\n\n\n\t\t\tInvalid Input!"); break; } } Console.ReadKey(); } }