Actions

Functions

From Jedisaber Wiki

A function is a block of code that only runs when it is called.

You can pass data to a function.

A function can return data as a result.

You can create a function by defining it:

def my_function():
 print("Hello from a function")


... and call it thusly:

my_function()


References

https://www.w3schools.com/python/python_functions.asp