Is there an elegant way of converting this string array:
string[] a = new[] {\"name\", \"Fred\", \"colour\", \"green\", \"sport\", \"tennis\"};
Since it's an array I would do this:
var result = Enumerable.Range(0,a.Length/2) .ToDictionary(x => a[2 * x], x => a[2 * x + 1]);