
- This event has passed.
3 PM – Intro To Python – Gamas
January 17 @ 3:00 pm - 4:00 pm
Today We Did
- We learned more about function
- We created triangle_area function
- We created circle_are function
Homework
- Create jan_17_many_function_2_hw.py. All of below homeworks are similar to what we did in the class today
- Create a function that can calculate the area of a rectangle.
- function name – rectangle_area
- function parameters – width, height
- Create a function that can calculate the volume of a rectangular prism
- function name – rectangular_prism_volume
- function parameters – width, height, depth
- Create a function that can do division of two numbers. Come up with a good function name and parameters.
- Create a function that can calculate perimeter of a triangle. Come up with a good function name and parameters
Calculate how many candies each person gets
- Function name:
candies_per_person - Parameters:
total_candies,people- When you call “candies_per_person(10, 2)” then it will output With 10 candies and 2 people, each person will get 5 candies.”
- When you call “candies_per_person(100, 5)” then it will output With 100 candies and 5 people, each person will get 20 candies.”
- Function name:
- Create jan_17_draw_face_hw.py
- Create a face function that can draw like this.
- function name – face
- parameter – x,y, eye_color, mouth_color

- Call the function two times with different coordinate
face_2(0,0, "green", "black") face_2(0,100, "brown", "red")
And it will produce like this

- Create a face function that can draw like this.