結果
| 問題 | No.204 ゴールデン・ウィーク(2) |
| コンテスト | |
| ユーザー |
cormoran
|
| 提出日時 | 2016-08-16 21:32:49 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
AC
|
| 実行時間 | 105 ms / 1,000 ms |
| コード長 | 395 bytes |
| 記録 | |
| コンパイル時間 | 347 ms |
| コンパイル使用メモリ | 20,700 KB |
| 実行使用メモリ | 15,360 KB |
| 最終ジャッジ日時 | 2026-05-30 08:03:46 |
| 合計ジャッジ時間 | 6,690 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 46 |
ソースコード
#!/usr/bin/env python3
import copy
n = int(input())
days = 'x' * 20 + input() + input() + 'x' * 20
ans = 0
for i in range(len(days)):
day2 = list(copy.copy(days))
for j in range(n):
if i + j < len(day2):
if day2[i + j] == 'o':
break
day2[i + j] = 'o'
ans = max(ans, max(map(lambda x: len(x), "".join(day2).split('x'))))
print(ans)
cormoran