mirror of
https://github.com/jlengrand/kotlin.git
synced 2026-05-08 08:31:26 +00:00
18 lines
256 B
Kotlin
Vendored
18 lines
256 B
Kotlin
Vendored
|
|
object O {
|
|
val mmmap = HashMap<String, Int>();
|
|
|
|
init {
|
|
fun doStuff() {
|
|
mmmap.put("two", 2)
|
|
}
|
|
doStuff()
|
|
}
|
|
}
|
|
|
|
fun box(): String {
|
|
val r = O.mmmap["two"]
|
|
if (r != 2) return "Fail: $r"
|
|
return "OK"
|
|
}
|