Python · Lesson 7.1 · Pro
Defining functions
Wrap a piece of logic in a named function you can call again and again.
In this lesson
- def makes a function
- return, not print
- Functions can use if and loops
- Call functions from functions
Go Pro to read this lesson
Pro unlocks every lesson and practice problem in SQL, Python, pandas and NumPy, with answers and step-by-step explanations.