1#use the def keyword to declare a function in Python
2def function(args,kwargs='attribute'):
3 #here is the returned value
4 return 'return value'
1# A basic function
2def func():
3 return 0
4
5# A function with arguments
6def func2(num1):
7 return num1
8
9# A function with type hints
10def func3(num2: int) -> int:
11 return num2