結果

問題 No.499 7進数変換
ユーザー lloyz
提出日時 2023-09-01 02:38:31
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 34 ms / 1,000 ms
コード長 182 bytes
コンパイル時間 240 ms
コンパイル使用メモリ 12,032 KB
実行使用メモリ 10,496 KB
最終ジャッジ日時 2025-01-03 05:08:00
合計ジャッジ時間 2,381 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 31
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())

ANS = []
while n > 0:
    n, r = divmod(n, 7)
    ANS.append(r)
if len(ANS) == 0:
    print(0)
else:
    ANS.reverse()
    print(''.join(map(str, ANS)))
0