Download presentation
Presentation is loading. Please wait.
Published byJune Jacobs Modified over 9 years ago
1
Unit 1: Programming
2
Programming Classwork: 1)Create a function that calculates the hypotenuse of a right triangle. Name: hypotenuse Inputs: A, B Output: C 2)Write a function that takes the N th root of a number. Name: root Inputs: x,n Output: y
3
Lockers At the end of the school year, an obsessive/compulsive worker is asked to clean out N lockers, initially all closed. Each time he cleans, he leaves the door open if it was closed, or closed if it was open. The first time he cleans, he leaves all the doors open. The second time, he closes every second door. The third time he cleans, he closes every third door if it is open, or opens it if was closed. The fourth time…well this continues until he has cleaned the lockers N times. How many lockers are open if N = 4? N=6? N = 1000?
4
k = 1k = 2k = 3k = 4 “Lockers” How many lockers are open if N = 4? N=6? N = 1000? Open Closed Open N = 4
5
The Bouncing Ball A student drops a rubber ball of mass, M, from a height, H, straight down onto a marble floor and watches as it bounces up and down. From her observations she concludes that there is a 10% loss in the energy of the ball each time it interacts with the floor. Assuming the ball is released from rest at a height of 1 meter… 1.Write a function to determine the potential energy of the ball for any time, T. Name: potentialEnergy Inputs: T Output: PE
6
The Bouncing Ball A student drops a rubber ball of mass, M, from a height, H, straight down onto a marble floor and watches as it bounces up and down. From her observations she concludes that there is a 10% loss in the energy of the ball each time it interacts with the floor. Assuming the ball is released from rest at a height of 1 meter… 1.Write a function to determine the kinetic energy of the ball at any time, T. Name: kineticEnergy Inputs: T Output: KE
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.