結果
| 問題 |
No.1313 N言っちゃダメゲーム (4)
|
| コンテスト | |
| ユーザー |
convexineq
|
| 提出日時 | 2020-12-10 09:56:13 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 48 ms / 2,000 ms |
| コード長 | 248 bytes |
| コンパイル時間 | 204 ms |
| コンパイル使用メモリ | 82,088 KB |
| 実行使用メモリ | 61,696 KB |
| 最終ジャッジ日時 | 2024-09-19 17:46:26 |
| 合計ジャッジ時間 | 2,864 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 35 |
ソースコード
n,k = map(int,input().split())
s = "o"+input()
dp = [0]*n
v = n
for i in range(n-1,-1,-1):
if i < v and s[i]=="o":
dp[i] = 1
v = i-k
if dp[0]==1:
print(0)
else:
ans = [i for i in range(1,k+1) if dp[i]==1]
print(*ans)
convexineq