Binary Permutation
Last updated
Was this helpful?
Last updated
Was this helpful?
Return all the permutations of a string, matching the sequence but only changing case.
For example:
The Idea: Begin from the base case (empty string), and branch out two different ways (capital and lowercase) to the parent string.
Complexity: O(2^n) time and space