American Young Coder (AYC)

AYC logo
Loading Events

« All Events

  • This event has passed.

6:00 PM- Python OOP -Joshua

June 5 @ 6:00 pm - 7:00 pm

Today We did

  • Explained the application loop
  • Talked about the theory behind having multiple files
  • Why the class variables in __init__ can help us have a “updating” school system that remembers students we add

 

Homework

  1. Implement the list_students(self): class    (Option 2)
    Hints/Steps

    1. In a for loop, you extract each student from the list
    2. Then with that student object, grab the name, age , and grade and write a f string with that information
    3. Sample Sentence   ” student.name is in student.grade and is student.age years old” (don’t forget to f string it with brackets
    4. Remember, you need to loop through self.student_list
  2. Find Student (Option 3)
    Hints

    1. Ask Only for the name you want to search (Changed from the explantion
    2. In a loop similar to the for loop in option 2, check each student’s name with an if statement to see if it is a match to the input
      1. If it is a match, print that student’s other information

So structure for Find student is

  • Ask for student’s name with
  • For loop for all the students
    • Check if the input isthe same as the student.name of each file
    • If found, print the same sample sentences option 2

Details

Date:
June 5
Time:
6:00 pm - 7:00 pm
Verified by MonsterInsights