Control flow

San Skulrattanakulchai

March 2, 2020

Topics

Assignment statements

Control flow & function call statements

Blocks

Blocks, continued

if statement

Nested if’s statement

Nested if’s statement’s use case

if expression

if expression, continued

when statement

when statement with argument

when statement with argument, continued

when statement without argument

when expression

An extra rule for when expression

while statement.

while statement’s use case

do statement

for statement

for statement, continued

for statement, continued

for statement, continued

nested loops

break

continue