1/24/00
COM1100 Winter2000 Lecture 7
17
Method 2 – pass by value
nQuestion: write a function that increments an integer.
nMethod 1: The user supplies the integer value (that does not need to be stored as an integer variable, but can be computed as the function call is made), by using the value argument. The function returns the incremented value as the function return value.