結果

問題 No.272 NOT回路
ユーザー javyjavy
提出日時 2015-11-14 05:11:39
言語 Kotlin
(1.9.23)
結果
AC  
実行時間 292 ms / 1,000 ms
コード長 962 bytes
コンパイル時間 11,556 ms
コンパイル使用メモリ 436,896 KB
実行使用メモリ 54,312 KB
最終ジャッジ日時 2024-04-30 07:24:05
合計ジャッジ時間 16,236 ms
ジャッジサーバーID
(参考情報)
judge3 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 285 ms
54,208 KB
testcase_01 AC 288 ms
54,228 KB
testcase_02 AC 287 ms
54,228 KB
testcase_03 AC 291 ms
54,224 KB
testcase_04 AC 292 ms
54,124 KB
testcase_05 AC 288 ms
54,244 KB
testcase_06 AC 286 ms
54,224 KB
testcase_07 AC 289 ms
54,236 KB
testcase_08 AC 287 ms
54,244 KB
testcase_09 AC 283 ms
54,216 KB
testcase_10 AC 284 ms
54,312 KB
testcase_11 AC 286 ms
54,036 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:6:10: warning: parameter 'args' is never used
fun main(args: Array<String>) {
         ^

ソースコード

diff #

package Yukicoder

/**
 * Created by hichikawa on 2015/11/12.
 */
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
    }

    if (readLineInt() == 1) {
        println(0)
    } else {
        println(1)
    }
}
0