Frage im Vorstellungsgespräch bei Tripadvisor

Leetcode easy- balanced bracket question with a single bracket.