avp26/u6/matching_brackets.py

6 lines
117 B
Python

def is_paired (input_string):
for char input_string:
if char in opening:
stack.append(char)