American Young Coder

AYC logo
Loading Events

« All Events

  • This event has passed.

3 PM – Python OOP – Gamas

April 5 @ 3:00 pm - 4:00 pm

Today We Did
  1. We exercises with function and list.
Homework
  1. Create apr_6_hw.py
  2. Create a new function “favorite_dance_style”
    1. It has 1 parameter: dance_style
    2. Inside the function print “I like ballet” if the parameter is equal to “ballet”
    3. Otherwise, print “I don’t like <dance_style>”
    4. Call the function like these
      1. favorite_dance_style(“ballet”)
      2. favorite_dance_style(“tango”)
  3. Create a list “friends”
    1. Add 3 names
    2. use for loop to print each name in the list.
    3. After the for loop, add the 4th name to the list: Gamas
    4. user for loop to print each name in the list, if the name is “Gamas” print “Gamas is my teacher”.

Details

Date:
April 5
Time:
3:00 pm - 4:00 pm