結果
| 問題 |
No.688 E869120 and Constructing Array 2
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-07-16 15:58:31 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 27 ms / 1,000 ms |
| コード長 | 257 bytes |
| コンパイル時間 | 338 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 10,752 KB |
| 最終ジャッジ日時 | 2024-11-30 22:13:57 |
| 合計ジャッジ時間 | 1,264 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 10 |
ソースコード
k = int(input())
if k == 0:
print(1)
print(0)
else:
for i in range(31):
for j in range(31):
if j*(j-1)/2 * 2**(i-j) == k:
print(i)
print(" ".join(['0']*(i-j) + ['1']*j))
break