C# program to Join two given strings


Following program shows you how to Join two given strings.
In this program we get strings from user and join those strings

using System;

class MainClass {
  public static void Main (string[] args) {
    Console.WriteLine ("Please enter the first string:");
    string string1 = Console.ReadLine();

    Console.WriteLine ("Please enter the second string:");
    string string2 = Console.ReadLine();

    string output = string1 + string2;
    Console.WriteLine("Joined string is: " + output);

  }
}

Output:

Please enter the first string:
 hello
Please enter the second string:
 jenni
Joined string is: hellojenni