tutorial |
---|
Functions are amazing because of many things, but mainly because you can encapsulate your code in pieces and re-use those pieces several times without having to type all that code again.
-
Please, write all of your code inside the
my_main_code
function. -
The function
is_odd
is defined at the beginning of the code, please call that function insidemy_main_code
passing it the number45345
and print the result on the console.
There's a series of exercises dedicated to functions here, we encourage you to go and finish those after your first function exercise (And then... come back! 😃).
- Check this out for additional information on functions and function calls: https://www.w3schools.com/python/python_functions.asp