Files
kotlin-fork/j2k/testData/fileOrElement/labelStatement/complicatedExampleFromJavaTutorial.kt
T
Alexander Udalov 3c859caf2b j2k: flatten test cases and testData directory structure
Move j2k/test/tests -> j2k/tests, j2k/test/testData -> j2k/testData
2015-01-03 00:52:59 +03:00

13 lines
312 B
Kotlin

@test for (i in 0..max) {
var n = substring.length()
var j = i
var k = 0
while (n-- != 0) {
if (searchMe.charAt(j++) != substring.charAt(k++)) {
continue@test
}
}
foundIt = true
break@test
}
System.out.println(if (foundIt) "Found it" else "Didn't find it")