Skip to content

Latest commit

 

History

History
 
 

balance_brackets

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

Balanced Brackets

Description

Given a sequence consisting of brackets, determine whether the expression is balanced. A sequence of brackets is balanced if every open bracket can be paired uniquely with a closed bracket that occurs after the former. Also, the interval between them must be balanced. You will be given three types of brackets: (, {, [.

([{}]) - this is balanced brackets

([{]}) - this is not balanced brackets