Match
os := 'windows'
print('V is running on ')
match os {
'darwin' => { println('macOS.') }
'linux' => { println('Linux.') }
else => { println(os) }
}
A match statement is a shorter way to write a sequence of if - else
statements. When a matching branch is found, the expression following the => will be evaluated. The else => branch will be evaluated when no other branches match.