Skip to content

Commit 85c7840

Browse files
Merge pull request #601 from CO18326/patch-3
parenthesisBalancing.py
2 parents 9e996a0 + 9954153 commit 85c7840

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Python/parenthesisBalancing.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ def checker(inp):
1010
pairs[']']='['
1111
stack=[]
1212
for i in list(inp):
13-
if i==']' and i=='}' and i==')':
13+
if i==']' or i=='}' or i==')':
1414
len(stack)==0 or stack.pop() != pairs[i] ? return False:pass
1515
else :
1616
stack.push(i)

0 commit comments

Comments
 (0)