Scala - IF ELSE Statements
This chapter takes you through the conditional construction statements in Scala programming.
if Statement‘if’ statement consists of a Boolean expression. If block executes only when condition is true otherwise execution of if block is skipped.
- // Statements to be executed
If not, the first set of code after the end of the ‘if’ expression (after the closing curly brace) will be executed.