A Class of Students
Jun 5, 2016
We need an application for teachers to keep track of students and their grades.
Assume for now, there is a single teacher and a single class. Here’s what you need to do.
Think of a way to store the student data in a file (say students.txt). An example format can be:
StudentName StudentPhoneNumber Marks1 Marks2 Marks3 Marks4
Read up on JSON and try to store data in JSON format.
- Create a Python class, Student. It’ll have all the attributes of the student (StudentName, StudentPhoneNumber, etc.)
- Make a function to read student data from file
- Make a function to add a new student to the file and remove a student from the file
- Make a function to edit student data
- Try making the above functions a member of the Student class (python class)
- Make a command line interface that asks me (teacher) what I want to do (add a student, remove a student, edit) and then calls the appropriate function