Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# linq aggregate string builder

string[] words = { "one", "two", "three" };
var res = words.Aggregate(
   "", // start with empty string to handle empty list case.
   (current, next) => current + ", " + next);
Console.WriteLine(res);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #linq #aggregate #string #builder
ADD COMMENT
Topic
Name
1+8 =