I have an array with n members. And I have another number: m,(m <= n) which is entered by user. Now I want to produce all of possible "m" member combination in the array.
A[5] = {a,b,c,d,e};
B = 3
Number of combination: C(5, 3) = 10
Now I want a code for showing these 10 combination.like:
{{a,b,c},{a,b,d},{a,b,e},.....}
Order of items in permutation is important. For example {a,b,d} is right but {b,d,a} is wrong. The permutation items should come in their order in our matrix.
I appropriate any help from your side. Thanks in advance