2. Variables in Scala
www.npntraining.com/masters-program/big-data-architect-training
❏ In Scala there are 2 types of variables
Mutable Variables (Read / Write):
❏ Mutable variables are the variables which allow us to change a value after the initializing a
variable.
❏ Mutable variables are defined by using the var keyword.
Immutable Variables (Read only) :
❏ Immutable variables are the variables which do not all us to change a value after the initializing a
variable.
❏ Immutable variables are defined by using the val keyword.
❏ Similar to Java Final variables.