I'm struggling with how to solve the following problem: I have a list of id's and values. The number of values associated to each id can be as low as one and as high as 24. I need to create a list of all possible combinations of values for each id. Below is an example of the input and the expected output. Any suggestions on how I could solve this?
Input
| id | Value |
| 1 | 17 |
| 1 | 552 |
| 2 | 17 |
| 2 | 58 |
| 2 | 120 |
| 3 | 120 |
Expected Output
| id | Combo 1 | Combo 2 | Combo 3 | Combo 4 | Combo 5 | Combo 6 | Combo 7 |
| 1 | 17 | 52 | 17, 552 | | | | |
| 2 | 17 | 58 | 120 | 17, 58 | 17, 120 | 58, 120 | 17, 58, 120 |
| 3 | 120 | | | | | | |