elect
09/28/2016, 4:34 PMval l = b?.length ?: -1
If the expression to the left of ?: is not null, the elvis operator returns it, otherwise it returns the expression >to the right. Note that the right-hand side expression is evaluated only if the left-hand side is null.