Append string and insert string to a StringBuilder : StringBuilder : String C# Examples


C# Examples » String » StringBuilder »

 

Append string and insert string to a StringBuilder









    
using  System;
using  System.Text;

class  MainClass
{
    static  void  Main(string[]  args)
    {
            StringBuilder  MyString  =  new  StringBuilder("Hello");
        
            MyString.Insert(0,  "My");
            MyString.Append("World");
        
            Console.WriteLine(MyString);

    }
}
    
   
  
   



Output

MyHelloWorld


HTML code for linking to this page:

Follow Navioo On Twitter

C# Examples

 Navioo String
» StringBuilder