結果
| 問題 |
No.2198 Concon Substrings (COuNt-CONstruct Version)
|
| コンテスト | |
| ユーザー |
rlangevin
|
| 提出日時 | 2023-01-20 22:49:55 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 293 bytes |
| コンパイル時間 | 372 ms |
| コンパイル使用メモリ | 82,720 KB |
| 実行使用メモリ | 72,720 KB |
| 最終ジャッジ日時 | 2024-06-23 10:50:11 |
| 合計ジャッジ時間 | 18,002 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 32 WA * 72 |
ソースコード
def Gauss(n):
return (n + 1) * (n + 2)//2
M = int(input())
S = set()
for i in range(20000, -1, -1):
if M >= Gauss(i):
S.add(i)
M -= Gauss(i)
ans = []
for i in range(20000):
if i in S:
ans.append("con")
else:
ans.append("co")
print(*ans, sep="")
rlangevin