Hi, here’s your problem today. This problem was recently asked by Apple:
Given a number n, generate all possible combinations of n well-formed brackets.
Here are some examples and some starting code.
def generate_brackets(n): #Fill this in.
print(generate_brackets(1))
[’()’]
print(generate_brackets(3))