9
The answer to this question is much too long
Your challenge is to write a partitioning function in the smallest number of characters.
Input example
['a', 'b', 'c']
Output example
[(('a'),('b'),('c')),
(('a', 'b'), ('c')),
(('a', 'c'), ('b')),
(('b', 'c'), ('a')),
(('a', 'b', 'c'))]
The input can be a list/array/set/string etc. whatever is easiest for your function to process
You can also choose the output format to suit yourself as long as the structure is clear.
Your function should work for at least 6 items in the input
shall the empty partition also be part of the output? – FUZxxl – 2015-04-24T09:24:35.347