I am wondering whether the complexity should be
Time: O(N ^ H) = O(N ^ N)
Stack Space: O(H) = O(N)
Space including list: O(N ^ N * 2 ^ N) = O(2N ^ N)
If I am wrong, please point it out. Also trying to figure this question out.
Different Ways to Add Parentheses