結果
問題 | No.457 (^^*) |
ユーザー |
![]() |
提出日時 | 2019-12-21 14:25:19 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 659 ms / 2,000 ms |
コード長 | 610 bytes |
コンパイル時間 | 159 ms |
コンパイル使用メモリ | 82,376 KB |
実行使用メモリ | 76,348 KB |
最終ジャッジ日時 | 2024-07-19 08:36:15 |
合計ジャッジ時間 | 3,950 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
ソースコード
S = input()n = len(S)l = r = 0for i in range(n-4):if S[i] != '(':continuelf = rf = Falselt = rt = ''for s in S[i+1:]:if s == ')':l += lfr += rfelif not lf & rf:if s == '*':if lt == '^^':lf = Trueif rt == '':rt += selif s == '^':if lt == '' or lt == '^':lt += sif rt == '*':rt += selif rt == '*^':rf = Trueprint(l, r)