Semantics : IfStatement

IfStatement  ::=  if ( ( )? Expr ( ) )? Statement
( ( elif | else if ) ( ( )? Expr ( ) )? Statement )*
( else Statement )?

Used by:  

This if -elif -else statement is a basic flow-control statement that should be familiar to any programmers. The parentheses for the condition expression are optional.