12.07.2015 Views

ILOG OPL Development Studio Language Reference Manual

ILOG OPL Development Studio Language Reference Manual

ILOG OPL Development Studio Language Reference Manual

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Compound statementsA compound statement is a sequence of statements and expressions enclosed in curly brackets({}). It can be used to perform multiple tasks whenever a single statement is expected, forexample, in the following conditional statement, the three statements and expressions in curlybrackets are executed when the condition a > b is true:if (a > b) {var c = aa = bb = c}The last statement or expression before a closing curly bracket does not need to be followedby a semicolon, even if it is on the same line. For example, the following program issyntactically correct and is equivalent to the previous one:if (a > b) { var c = a; a = b; b = c }I L O G O P L D E V E L O P M E N T S T U D I O L A N G U A G ER E F E R E N C E M A N U A L179

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!