Copyright © 1996, 1997 Lucent Technologies Inc. All rights reserved.

9.4 Conditional statements

The conditional statement takes two forms:


if ( expression ) statement if ( expression ) statement else statement
The expression is evaluated; it must have type int. If it is non-zero, then the first statement is executed. In the second form, the second statement is executed if the expression is 0. The statement after else is connected to the nearest else-less if.

05/Jun/97