結果

問題 No.499 7進数変換
ユーザー 👑 はまやんはまやんはまやんはまやん
提出日時 2017-06-01 17:08:49
言語 Kotlin
(1.9.23)
結果
AC  
実行時間 260 ms / 1,000 ms
コード長 205 bytes
コンパイル時間 8,971 ms
コンパイル使用メモリ 429,836 KB
実行使用メモリ 54,344 KB
最終ジャッジ日時 2024-04-30 13:28:10
合計ジャッジ時間 17,861 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 257 ms
54,176 KB
testcase_01 AC 253 ms
54,232 KB
testcase_02 AC 250 ms
54,236 KB
testcase_03 AC 251 ms
54,224 KB
testcase_04 AC 247 ms
54,260 KB
testcase_05 AC 252 ms
54,344 KB
testcase_06 AC 252 ms
54,156 KB
testcase_07 AC 257 ms
54,244 KB
testcase_08 AC 244 ms
54,140 KB
testcase_09 AC 249 ms
54,036 KB
testcase_10 AC 253 ms
54,128 KB
testcase_11 AC 246 ms
54,232 KB
testcase_12 AC 249 ms
54,152 KB
testcase_13 AC 251 ms
54,156 KB
testcase_14 AC 247 ms
54,268 KB
testcase_15 AC 249 ms
54,124 KB
testcase_16 AC 252 ms
54,140 KB
testcase_17 AC 252 ms
54,260 KB
testcase_18 AC 257 ms
54,248 KB
testcase_19 AC 257 ms
54,092 KB
testcase_20 AC 260 ms
54,240 KB
testcase_21 AC 252 ms
54,056 KB
testcase_22 AC 248 ms
54,164 KB
testcase_23 AC 256 ms
54,088 KB
testcase_24 AC 242 ms
54,224 KB
testcase_25 AC 259 ms
54,056 KB
testcase_26 AC 250 ms
54,124 KB
testcase_27 AC 247 ms
54,148 KB
testcase_28 AC 246 ms
54,264 KB
testcase_29 AC 254 ms
54,264 KB
testcase_30 AC 257 ms
54,160 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:1:10: warning: parameter 'args' is never used
fun main(args: Array<String>) {
         ^

ソースコード

diff #

fun main(args: Array<String>) {
    var N = readLine()!!.toInt()

    var ans = ""
    if(N == 0) ans = "0"
    while(0 < N) {
        ans = (N % 7).toString() + ans
        N /= 7
    }
    println(ans)
}
0