Previous Lecture lect03 Next Lecture

Resources from lecture

Today’s lecture:

Concept Questions

Function definition

def double(n): ‘’’ Returns 2 times the parameter ‘’’ return 2 * n

’’’

print(double(“2”)) print(type(double(“2”))) print(double(2.5)) print(type(double(2.5))) print(double([2,4,6]))

pytest

Good defensive coding style means that you think about how you would test your code.

```