inheritance would make sense here.
But a couple things
But a couple things
- you can get rid of the private variables as well as the getters and setters. If you need the class variables, just use them.
- use format not concatenation
Quote:return "ID: " + self.iden + " " + " First: " + self.first_name + " Last Name: " + self.last_name + " " + " Type: " + self.student_type'
return "ID: {} First: {} Last Name: {} Type: {}".format(self.iden, self.first_name, self.last_name, self.student_type)
Recommended Tutorials: