string type

To store an immutable sequence of unicode char, we can use string(System.String) type.

C# uses double quote to wrap string literals.


using System;

class Program
{
    static void Main(string[] args)
    {
        string str = "demo from java2s.com";
        Console.WriteLine(str);


    }
}

The output:


demo from java2s.com
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.