next up previous contents index
Next: Conditional Control Flow Up: Compound Statements Previous: Compound Statements

Unconditional Control Flow

       

There are four statements that specify unconditional control flow: halt, continue, exit, return. The halt statement stops program execution. The continue and exit statements are used in iterative control constructs. The former skips to the next iteration of the nearest enclosing loop and the latter exits the nearest enclosing loop. Finally, the return statement terminates a procedure call and returns control to the calling procedure. For procedures with return values, return is followed by an expression that is the return value.



Kay Nettle
Fri Feb 21 21:14:29 CST 1997