Use SelectMany to flatten nested collections?
Use SelectMany to flatten nested collections
var nested = new List<List<string>> {
new() { "A", "B" },
new() { "C", "D" }
var flat = nested.SelectMany(x => x);
Use SelectMany to flatten nested collections
var nested = new List<List<string>> {
new() { "A", "B" },
new() { "C", "D" }
var flat = nested.SelectMany(x => x);