0 / 60 seg.

Which line of code is a shorter, more idiomatic version of the displayed snippet?

val len: Int = if (x != null) x.length else -1