I think I have confused at least half the class with my explanation of parameter passing! Or at least maybe not my explanation but certainly my attempted explanation of the NAB type question.
Let me try and simplify it again:
Call by value means a copy of a variable is used in a sub-routine. If it changes the variable, only the copy is changed, not the original.
Call by reference uses the original variable (by referring to the address of the variable rather than a copy). If it changes, then the original is changed also.
If you understand that then you are probably fine! The NAB question was confusing as it lacked some important details.
The other thing we did to day was functions. The important thing about them is that they produce a value. For example random produces a random number.
Here is the powerpoint on parameter passing:
