Oracle Interview Question

which data structure will you use to remove redundant brackets in an expression and how will you implement it.