Let's define the following simple function:
Hello
and a given name in the following way:>>> def print_hello(name): ... print('Hello ' + name) ...
Call the function as follows:
>>> print_hello('Ivan') Hello Ivan
>>> def print_hello(name='Ivan'): ... print('Hello ' + name) ... >>> print_hello() Hello Ivan
>>> def double(number): ... return 2 * number ... >>> double(3) 6