結果

問題 No.2038 Strange Arrange
ユーザー 👑 tamatotamato
提出日時 2022-08-12 21:59:40
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 38 ms / 2,000 ms
コード長 417 bytes
コンパイル時間 162 ms
コンパイル使用メモリ 81,788 KB
実行使用メモリ 53,556 KB
最終ジャッジ日時 2023-10-24 23:13:31
合計ジャッジ時間 991 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 38 ms
53,556 KB
testcase_01 AC 35 ms
53,556 KB
testcase_02 AC 37 ms
53,556 KB
testcase_03 AC 35 ms
53,556 KB
testcase_04 AC 35 ms
53,556 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

mod = 998244353


def main():
    import sys
    input = sys.stdin.readline

    A = []
    k = 1
    i = 1
    limit = 2
    while k < 10:
        if i & 1:
            A.append(1)
        else:
            if i == limit:
                k += 1
                limit = i * 2 + 2
            A.append(k)
        i += 1

    N = int(input())
    print("".join(map(str, A[:N])))


if __name__ == '__main__':
    main()
0