Function arguments

To define a function with arguments, include the argument names inside the parentheses:

func add(a, b):
    return a + b

You can also define the types of the arguments.

func add(a: int, b: int):
    return a + b
Comments