CIT130 2.4 Practice

Functions should be given names that reflect their purpose.

True.

Function headers are terminated with a semicolon.

False.

Function prototypes are terminated with a semicolon.

True.

If other functions are defined before the main, the program still starts executing at the main function.

True.

When a function terminates, it always branches back to the main, regardless where it was called from.

False.

Arguments are passed to the function parameters in the order they appear in the function call.

True.

The scope of the parameter is limited to the function which uses it.

True.

Changes to a function parameter always affect the original argument as well.

False

In a function prototype, the names of the parameter variables may be left out.

True.

Many functions may have local variables with the same name.

True.

Overuse of global variables can lead to problems.

True.

Static local variables are not destroyed when a function returns.

True.

All static variables are initialized to -1 by default.

False

Initialization of static local variables only happen once, regardless of how many times the function in which they are defined is called.

True

When a function with default arguments is called and an argument is left out, all arguments that come after it must be left out as well.

True

It is not possible for a function to have some parameters with default arguments and some without.

False

The exit function can only be called from the main.

False

A stub is a dummy function that is called instead of the actual function it represents.

True