LINQ swap columns into rows

前端 未结 5 1954
死守一世寂寞
死守一世寂寞 2020-12-06 10:44

Is there a fancy LINQ expression that could allow me to do the following in a much more simpler fashion. I have a List>, assuming the L

5条回答
  •  渐次进展
    2020-12-06 11:45

    You could LINQify the inner loop pretty easily:

    vector.AddRange(values.Select(value => value[i]));

    Whether or not that improves the readability is left entirely up to you!

提交回复
热议问题