Generate all combinations of the given array
ChatGPT
genCombinations(['a', 'b', 'c'])// => ['a', 'b', 'ab', 'c', 'ac', 'bc', 'abc'] Copy
genCombinations(['a', 'b', 'c'])// => ['a', 'b', 'ab', 'c', 'ac', 'bc', 'abc']
Generate all combinations of the given array