Mike
01/16/2019, 12:49 PMprintln
What am I missing? I would have expected the val to require an initial value, and complain if it’s assigned, but it appears not.Pavlo Liapota
01/16/2019, 12:56 PMlocal
variable is always assigned before it is used and never reassigned, so it is fine by compiler.Pavlo Liapota
01/16/2019, 12:58 PMval local =
if (a == 1)
"12.0".toBigDecimal()
else
"13.0".toBigDecimal()
return local
Mike
01/16/2019, 12:59 PMif
as an expression, but nice to know it’s there.