Concat method with a String array. : String Concat « String « C# / CSharp Tutorial






using System;

public class ConcatTest {
    public static void Main() {
        string [] s = { "hello ", "and ", "welcome ", "to ", "this ", "demo! " };

        Console.WriteLine(string.Concat(s));

        Array.Sort(s);
        Console.WriteLine(string.Concat(s));
    }
}








5.8.String Concat
5.8.1.Append strings using Concat()
5.8.2.Concatenate string with integers
5.8.3.Mix string and integer in string cancatenation
5.8.4.Concatenate string with non-strings
5.8.5.String concatenation
5.8.6.Concat method with a String array.