Please enable JavaScript.
Coggle requires JavaScript to display documents.
programming features (Procedures and Functions (Benefits of using
…
programming features
Procedures and Functions
-
What is a function
Functions are pre-written parts of code
that can be used multiple times in the code. They are
used in procedures
-
-
-
-
Passing parameters
Passing by reference
If a parameter is passed by reference it means
that the value that is being passed in is going
to change
This means that any changes made in
the subroutine will result in a change to
the original value that was in the parameter
Arrays are always passed by reference because
if they were passed by value everything in that array
would have to be copied, so we pass them by reference
and this saves on memory
-