Anonymous user
Loops/Continue: Difference between revisions
→{{header|Kotlin}}: Updated example see https://github.com/dkandalov/rosettacode-kotlin for details
No edit summary |
(→{{header|Kotlin}}: Updated example see https://github.com/dkandalov/rosettacode-kotlin for details) |
||
Line 1,000:
=={{header|Kotlin}}==
<lang scala>// version 1.
fun main(args: Array<String>) {
for(i in 1 .. 10) {
if (i % 5 == 0) {
println(i)
continue
Line 1,010:
print("$i, ")
}
}</lang>▼
▲</lang>
{{out}}
|