Scala if then else syntax (and returning a value from an if statement)
Briefly

In Scala 3, the if/then/else syntax is different as it uses the 'then' keyword and does not require parentheses or curly braces.
Scala if/then statements return a value, like a ternary operator, allowing assignment of results to variables or use as function bodies.
Read at Alvinalexander
[
add
]
[
|
|
]