how do you get to the amount of the combinations? for l=4 there are more than 4 combinations: (((xx)x)x) ((xx)(xx)) ((x(xx))x) (x((xx)x)) (x(x(xx)))
you can print the input the very same way you print your solution, to see which cases your code is failing
If you already returned something, your function is already "finished", so you will never get to the final (unconditional) return.
Loading collection data...
how do you get to the amount of the combinations?
for l=4 there are more than 4 combinations:
(((xx)x)x)
((xx)(xx))
((x(xx))x)
(x((xx)x))
(x(x(xx)))
you can print the input the very same way you print your solution, to see which cases your code is failing
If you already returned something, your function is already "finished", so you will never get to the final (unconditional) return.