How to join strings into a single string in C#

1 Answer

0 votes
using System;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] movies = { "Frozen Fever", "Insurgent", "Whiplash", "Jupiter Ascending" };
            
            string join_strings = string.Join(" | ", movies);

            Console.WriteLine(join_strings);
        }
        
    }
}

/*
run:
  
Frozen Fever | Insurgent | Whiplash | Jupiter Ascending

*/


answered Feb 26, 2015 by avibootz

Related questions

1 answer 221 views
1 answer 171 views
1 answer 190 views
2 answers 214 views
1 answer 124 views
1 answer 169 views
1 answer 209 views
...