Higher Revision Notes
Software Development Process
Variables and Parameter passing By reference:
can change the value of the original parameter being passed in so effectively passes back the new value to all procedures where that variable is in scope.
creates a copy of the parameter being passed to a procedure and so does not change the value of the original out with the procedure. (IN only)
is declared and used within a procedure. Does not affect other local variables of same name in other procedures.
is available to all procedures where it is in scope. Can lead to undesired side effects in complex programs.
Scope of a variable
refers to the parts of the code when a variable is being used and exists in memory. When that part of the code is not being used the variable does not exist in memory. A global variable exists in memory throughout a whole program. A local variable only exists in memory when the procedure it is declared in, is called. It is often likened to the lifetime of the variable.
User-defined Function. Carries out a very specific computation designed by the software developer and returns a single value to the call. ( Most programming languages have pre-defined functions e.g. MID$. )
High level programming language constructs String operations -
concatenation â€“ joining of strings of text. String slicing - produces substrings (usually Left, Mid , Right functions) formatting of I/O.
CASE (or equivalent multiple outcome selection) IF and Nested IFs
Fixed loops, conditional loops.
AJN2007 Version 1.0
A summary of the Higher Computing Software Development Unit.