| @ -0,0 +1,16 @@ | |||||
| #!/usr/bin/env python3 | |||||
| #title :5-1.py | |||||
| #description :Opdracht 5.1 - Functie met drie parameters | |||||
| #author :Marcel Haazen | |||||
| #email :marcel@haazen.xyz | |||||
| #date :21-09-2019 - 23:54 | |||||
| #version :0.1 | |||||
| #usage :python3 5-1.py | |||||
| #notes : | |||||
| #python_version :3.7.4 | |||||
| #============================================================================== | |||||
| def som(getal1, getal2, getal3): | |||||
| print(sum([getal1,getal2,getal3])) | |||||
| som(1,2,4) | |||||
| @ -0,0 +1,16 @@ | |||||
| #!/usr/bin/env python3 | |||||
| #title :5-2.py | |||||
| #description :Opdracht 5.2 - Functie met list-parameter | |||||
| #author :Marcel Haazen | |||||
| #email :marcel@haazen.xyz | |||||
| #date :21-09-2019 - 23:58 | |||||
| #version :0.1 | |||||
| #usage :python3 5-2.py | |||||
| #notes : | |||||
| #python_version :3.7.4 | |||||
| #============================================================================== | |||||
| def som(getallenLijst): | |||||
| print(sum(getallenLijst)) | |||||
| som([1,2,7]) | |||||