Blocks

Blocks of code are denoted with brackets {}.

Blocks can be assigned to variables, in which case they are executed and their last expression is returned.

val result = {
    val temp = 161

    temp * 2    // This will be assigned to `result`
}

print(result)   // 322thp
    
Syntax error: Expected an expression after the equal `=` operator at line 1:11