結果

問題 No.688 E869120 and Constructing Array 2
ユーザー H20
提出日時 2021-08-31 13:25:05
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 38 ms / 1,000 ms
コード長 178 bytes
コンパイル時間 253 ms
コンパイル使用メモリ 82,724 KB
実行使用メモリ 53,120 KB
最終ジャッジ日時 2024-11-25 08:07:35
合計ジャッジ時間 1,491 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 10
権限があれば一括ダウンロードができます

ソースコード

diff #

K = int(input())
for i in range(1,31):
    for j in range(31-i):
        if K == i*(i-1)//2*pow(2,j):
            print(i+j) 
            print(*([1]*i+[0]*j))
            exit()
0