У меня есть список целых чисел в моей программе на С#. Тем не менее, я знаю количество элементов, которые у меня есть в моем списке, только во время выполнения.
Скажем, для простоты мой список {1, 2, 3} Теперь мне нужно создать все возможные комбинации следующим образом. {1, 2, 3} {1, 2} {1, 3} {2, 3} {1} {2} {3}
Может кто-нибудь помочь с этим?