when to use python functions code example
Example 1: def function in python
OK, basically def function() is a block where you will have one task that you can repeat all over again in the code to make it look short and clean
Example 2: python function
def name():#name of the def(function);
print("Hallo, World!")#Output is Hallo, World!;
name()#Name of the def, the programm will jump to the def;
#output:
#Hallo, World!