How do I go about getting a combination of an array of strings of count 2? Ie.
List myString = {\"a\", \"b\", \"c\", \"d\", \"f\"};
Not using LINQ
List myString = {"a", "b", "c", "d", "f"}; List result = new List (); for (int i = 0; i < myString.Count; i++) { for (int j = 0; j < myString.Count; j++) { if (i == j) continue; result.Add(myString[i] + myString[j]); } }