Netcracker Technology Interview Question

Paratheses balancing using stack.