Correct Sequence of brackets is always of primary importance both for written programs and mathematical expressions. By correct sequence we mean that for every opening bracket there is a closing bracket. The problem is to write a program that takes a random sized (size max 15) input of brackets from user, as a string, and can validate the sequence for e.g.

{([]{()})} valid

{[]}(} invalid

[]{{{} invalid

(((}))) invalid

{{{}}}} invalid

guys pls help me out with this

0