solved longest valid parentheses