The if
statement is for flow control.
int i = 7; if ( i > 10 ) { printf( 'i > 10' ); }
You can also do:
if ( i > 10 ) printf( 'i > 10' );
But don't, because when you add another result:
if ( i > 10 ) printf( 'i > 10' ); call_some_func();
Even though it's indented, call_some_func()
is always executed,
regardless of the if