Adding new functions

Python comes with many built-in functions (most of them in modules)

Sometimes, new functions are added

  • new functions are built as a combination of existing python components (functions)

  • the definition of a new function is given in the main program or in an associated file

  • a new function can be used anywhere in the program (in most cases)