Files
kotlin-fork/j2k/testData/fileOrElement/switch/fallDown.kt
T
Pavel V. Talanov 59f192ef90 Replace 'class object' with 'default object' in renderers and test data
Includes changes to decompiled text
Old syntax is used in builtins and project code for now
2015-03-06 19:36:54 +03:00

17 lines
470 B
Kotlin

package switch_demo
public class SwitchDemo {
default object {
public fun main(args: Array<String>) {
val month = 8
val monthString: String
when (month) {
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 -> monthString = "December"
else -> monthString = "Invalid month"
}
System.out.println(monthString)
}
}
}
fun main(args: Array<String>) = SwitchDemo.main(args)