For this challenge we will create a program to be used by a teacher at a start of a lesson to take the register. The program will go through a class list and for each pupil in the list, will ask the teacher if the pupils is present (y) or absent (n).
The program will then output the total number of students in the class, the number of students present and the number of students who are absent.
Flowchart / Algorithm
We have designed the following flowchart for this program. This algorithm uses a list called pupils used to store the names of all the students in the class.
Your tasks is to type the Python code following the steps identified in the above flowchart.