What i am trying to figure out is an algorithm that will create possible pairs irrespective of order in a indefinite set of values.
for example let's say the set is A,B,C,D,E
then possible sets are
AB AC AD AE BC CD DE
but... i also want pairs of more than 2 values.
for example
ABC ABD ABE BCD BCE
but also ABCD or ABCE. The problem here is that i want to make a method with input an array of Strings STring[] and the output would be a list of Strings in pair of 2,3.... up to number of values -1.
If anyone has a thought of a solution please help. :)