結果
問題 | No.82 市松模様 |
ユーザー | Pump0129 |
提出日時 | 2018-03-30 04:05:39 |
言語 | Kotlin (1.9.23) |
結果 |
AC
|
実行時間 | 319 ms / 5,000 ms |
コード長 | 475 bytes |
コンパイル時間 | 12,942 ms |
コンパイル使用メモリ | 412,944 KB |
実行使用メモリ | 53,088 KB |
最終ジャッジ日時 | 2023-08-12 22:54:08 |
合計ジャッジ時間 | 16,709 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge10 |
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 280 ms
52,712 KB |
testcase_01 | AC | 285 ms
52,688 KB |
testcase_02 | AC | 286 ms
52,632 KB |
testcase_03 | AC | 283 ms
52,692 KB |
testcase_04 | AC | 290 ms
52,992 KB |
testcase_05 | AC | 287 ms
52,520 KB |
testcase_06 | AC | 288 ms
52,612 KB |
testcase_07 | AC | 314 ms
52,956 KB |
testcase_08 | AC | 318 ms
52,892 KB |
testcase_09 | AC | 319 ms
53,088 KB |
コンパイルメッセージ
Main.kt:3:10: warning: parameter 'args' is never used fun main(args: Array<String>) { ^
ソースコード
package net.ipipip0129.kotlin.yukicoder fun main(args: Array<String>) { val data = readLine()!!.split(" ") val width = data[0].toInt() val height = data[1].toInt() val isODD = width % 2 == 0 var isBlack = data[2] == "B" for (j in 0 until height) { for (i in 0 until width) { print(if (isBlack) "B" else "W") isBlack = !isBlack } if (isODD) isBlack = !isBlack println() } }