Question d’entretien chez LinkedIn

Valid parentheses with other characters, e.g. (()e45)

Réponse à la question d'entretien

Utilisateur anonyme

22 déc. 2018

Traverse the string, use a basic count with "(" => +1 , ")" =>-1 , skipping any other characters. If the count is ever < 0 or the ending count != 0 then it's not valid.