Files
kotlin-fork/idea/testData/intentions/useWithIndex/simple.kt.after
T
2016-08-16 17:38:13 +03:00

8 lines
179 B
Plaintext
Vendored

// WITH_RUNTIME
fun foo(list: List<String>): Int? {
for ((index, s) in list.withIndex()) {
val x = s.length * index
if (x > 0) return x
}
return null
}