I\'m having a List, which is return from the remote data source (i.e., WCF). So, I need to modify the following data into a user-frien
>
Here is a extension method
public static IEnumerable> Pivot(this IEnumerable> source)
{
var enumerators = source.Select(e => e.GetEnumerator()).ToArray();
try
{
while (enumerators.All(e => e.MoveNext()))
{
yield return enumerators.Select(e => e.Current).ToArray();
}
}
finally
{
Array.ForEach(enumerators, e => e.Dispose());
}
}
so you can
var result = PersonInfo.Pivot();