Add two lists / Combine lists in C#
var result = list1.Concat(list2); ListaddedList = result.ToList();
Here you go wit an example
Listlist1 = new List (); list1.Add("One"); list1.Add("Two"); List list2 = new List (); list2.Add("three"); list2.Add("four"); var result = list1.Concat(list2); List addedList = result.ToList();
No comments:
Post a Comment