結果

問題 No.83 最大マッチング
ユーザー javyjavy
提出日時 2015-12-01 10:10:57
言語 Kotlin
(1.9.23)
結果
AC  
実行時間 494 ms / 5,000 ms
コード長 1,266 bytes
コンパイル時間 10,161 ms
コンパイル使用メモリ 438,380 KB
実行使用メモリ 65,564 KB
最終ジャッジ日時 2024-04-30 11:33:25
合計ジャッジ時間 15,190 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 249 ms
54,132 KB
testcase_01 AC 245 ms
54,304 KB
testcase_02 AC 245 ms
54,280 KB
testcase_03 AC 243 ms
54,092 KB
testcase_04 AC 246 ms
54,484 KB
testcase_05 AC 242 ms
54,136 KB
testcase_06 AC 245 ms
54,392 KB
testcase_07 AC 243 ms
54,228 KB
testcase_08 AC 239 ms
54,160 KB
testcase_09 AC 353 ms
63,248 KB
testcase_10 AC 452 ms
63,240 KB
testcase_11 AC 494 ms
65,308 KB
testcase_12 AC 484 ms
65,564 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:3:10: warning: parameter 'args' is never used
fun main(args: Array<String>) {
         ^

ソースコード

diff #

package Yukicoder

fun main(args: Array<String>) {
    fun readLineLongArray(): List<Long> {
        val str = readLine() as String
        val arrStr = str.split(" ")
        val ret = arrStr.map { it.toLong() }
        return ret
    }

    fun readLineLong(): Long {
        val str = readLine() as String
        return str.toLong()
    }

    fun readLineInt(): Int {
        val str = readLine() as String
        return str.toInt()
    }

    fun readLineIntArray() : List<Int> {
        val str = readLine() as String
        val arrStr = str.split(" ")
        val ret = arrStr.map { it.toInt() }
        return ret
    }

    fun readLineDoubleArray(): List<Double> {
        val str = readLine() as String
        val arrStr = str.split(" ")
        val ret = arrStr.map { it.toDouble() }
        return ret
    }

    fun readLineDouble() : Double {
        val str = readLine() as String
        return str.toDouble()
    }


//    fun readLineStringArray(): List<String> {
//        val str = readLine() as String
//        val arrStr = str.split(" ")
//        return arrStr
//    }

    var num = readLineInt()
    if (num % 2 == 1) {
        print(7)
        num -= 3
    }
    for (i in num downTo 2 step 2) {
        print(1)
    }
    println()
}
0