|
|
|
|
|
by ma_mazmaz
4265 days ago
|
|
In Scala, most variables should be val (i.e. constant) from a design perspective. That is, it is better, in Scala, to write code that does not have changing variable. Thus, using val instead of var is simply a check on the code, much in the same way that static typing provides a benefit over dynamic typing. |
|
A non-trivial number of people would dispute that ;-)