Skip to content

Latest commit

 

History

History
47 lines (29 loc) · 867 Bytes

File metadata and controls

47 lines (29 loc) · 867 Bytes

English Version

题目描述

给出 n 代表生成括号的对数,请你写出一个函数,使其能够生成所有可能的并且有效的括号组合。

例如,给出 n = 3,生成结果为:

[
  "((()))",
  "(()())",
  "(())()",
  "()(())",
  "()()()"
]

解法

Python3

Java

...