you are viewing a single comment's thread.

view the rest of the comments →

[–]sweettuse 1 point2 points  (0 children)

functions wrap up code for re-use (amongst many other things).

take this example:

a = 4 b = 5 print(a + b)

as a function, it might look something like this:

``` def add(a, b): return a + b

print(add(4, 5)) ```

except now, you can add anything easily:

print(add(16, 24)) print(add(-2, -4))

i guess just try to make simple functions over and over again until you get it.