結果
問題 | No.486 3 Straight Win(3連勝) |
ユーザー |
![]() |
提出日時 | 2025-03-26 15:43:58 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 37 ms / 2,000 ms |
コード長 | 379 bytes |
コンパイル時間 | 209 ms |
コンパイル使用メモリ | 82,248 KB |
実行使用メモリ | 52,096 KB |
最終ジャッジ日時 | 2025-03-26 15:44:06 |
合計ジャッジ時間 | 2,261 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 28 |
ソースコード
s = input().strip()current_east = 0current_west = 0winner = Nonefor c in s:if c == 'O':current_east += 1current_west = 0else:current_west += 1current_east = 0if current_east >= 3 or current_west >= 3:winner = 'East' if current_east >= 3 else 'West'breakprint(winner if winner is not None else 'NA')