I have a set of products that must be scheduled. There are P products each indexed from 1 to P. Each product can be scheduled into a time period 0 to T. I need to construct
000 001 010 011 100 101 110 111
for each binaryNumber in ar{ for i = 0 to n-1{ if binaryNumber(i) = 1 permunation.add(products(i)) } permunations.add(permutation) }
example: if binaryNumber= 001 then permunation1 = product1 if binaryNumber= 101 then permunation1 = product3,product1