Pergunta de entrevista da empresa Google

Simplifying a string expression containing multiple brackets and operands such as +, - . I had to remove all the brackets and simplify the expression.