A function returns the None object by default if the "return" statement is not mentioned in the function. A return statement with no expression in it also returns None.
Here are examples:
Without return statement>>> def fnc(a,b):... c=a+b...>>> print(fnc(2,3))NoneReturn without any expression>>> def fnc(a,b):... c=a+b... return...>>> print(fnc(2,3))None
Without return statement
>>> def fnc(a,b):... c=a+b...>>> print(fnc(2,3))None
Return without any expression
>>> def fnc(a,b):... c=a+b... return...>>> print(fnc(2,3))None