Question 18: Lists+

Classroom Attendance Manager App

Imagine you’re building an app for a teacher to manage classroom attendance. The app will allow the teacher to record student attendance, update attendance lists, and generate attendance summaries. This app will help the teacher efficiently manage their records.


Scenario

A teacher wants to keep track of which students are present in their class. They also want the ability to update the attendance list, count total students present, and correct any mistakes. Your app will provide a simple and user-friendly way to manage attendance.


Instructions

1. Create an Attendance List

  • Start with a list of students who are initially marked as present.

2. Manage Attendance

  • Provide the teacher with the following options:
    1. Add a student to the attendance list.
    2. Insert a student into a specific position in the list.
    3. Count the total number of students present.
    4. Count how many times a specific student is listed.
    5. Replace a student’s name with a new name (e.g., correcting spelling errors).
    6. Display the full attendance list.

3. Use a For Loop

  • Continuously display the menu and process the teacher’s choices until they decide to exit.

4. Provide a Final Summary

  • At the end of the session, display the final attendance list and the total number of students.
Write what you are looking for, and press enter to begin your search!