Many Scores Force Many Reads: An Optimality Proof for Score of Parentheses
A two-character padding argument extends the result to every even input length, proving an $\Omega(n)$ worst-case time lower bound, and the one-pass algorithm is therefore asymptotically optimal in the unit-cost RAM model.