Slide 7
Slide 7 text
Javier Gonzalez-Sanchez | CSE110 | Summer 2020 | 13
Block Statements
• Several statements are grouped together into a
block statement
• A block is delimited by braces: {...}
• For example, in an if-else statement, the if portion,
or the else portion, or both, could be block
statements
• There is no need to use braces if there is only one
statement or one set of “if-else” within the outer “if”
statement