class SchoolController: def __init__(self): self.view = View() self.db = SchoolDB() def run(self): self.view.welcome_screen() user_selection = int(self.view.menu()) if user_selection == 1: all_students = self.db.all_students() self.view.parse_students(all_students) elif user_selection == 2: name = self.view.get_student_name() age = self.view.get_student_age() new_student = Student(name, age) self.db.add_student(new_student) elif user_selection == 3: student = self.db.get_student() return self.run()