You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# In Python functions are 'groups of related statements' that can be called together, that typically perform a specific task, and which may or may not take a set of parameters or return a value.
# Functios allow you to assign a name to a 'code block' that performs a concrete computation. These named code blocks can be reused quickly because you can use their name to call them from different places in your code.
# Basic elements of a 'user defined' function
def print_msg(): # name of the function 'print_msg()'
print('Hello World!') # Statement to execute # also known as body of the function
print_msg() # calling the function # A function call consists of the function’s name