結果
問題 |
No.2398 ヒドラ崩し
|
ユーザー |
![]() |
提出日時 | 2025-06-12 12:49:46 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 271 bytes |
コンパイル時間 | 172 ms |
コンパイル使用メモリ | 82,240 KB |
実行使用メモリ | 73,904 KB |
最終ジャッジ日時 | 2025-06-12 12:49:49 |
合計ジャッジ時間 | 2,733 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 17 WA * 14 |
ソースコード
H = input().strip() stack = [] depths = [] for c in H: if c == '(': stack.append(len(stack) + 1) else: if stack: depth = stack.pop() depths.append(depth) xor = 0 for d in depths: xor ^= d print(0 if xor != 0 else 1)