結果

問題 No.600 かい文回
ユーザー mkawa2
提出日時 2020-05-30 15:50:23
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
WA  
実行時間 -
コード長 296 bytes
コンパイル時間 207 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 10,880 KB
最終ジャッジ日時 2024-11-07 18:33:00
合計ジャッジ時間 2,252 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 19 WA * 2
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys

def II(): return int(sys.stdin.readline())

def main():
    n=II()
    if n==1:
        print("a")
        exit()
    ans=""
    i=97
    while n>1:
        ans+=chr(i)
        if n&1:
            n-=1
            i+=1
        else:
            n>>=1
    print(ans+ans[::-1])

main()
0