Pregunta de entrevista de Autodesk

create a function which gets a string containing parentheses and return a boolean identifying if the parentheses are valid or not. then define the different type of invalid strings. then assume that it can also include [] and {}