Print String Lower Case, Upper Case and First Letter Uppercase

  1. using System;  
  2. using System.Globalization;  
  3. using System.Threading;  
  4. namespace ConsoleApplication10   
  5. {  
  6.     class Program   
  7.     {  
  8.         static void Main(string[] args)   
  9.         {  
  10.             string str = "surya pratap singh";  
  11.             CultureInfo culture = Thread.CurrentThread.CurrentCulture;  
  12.             TextInfo text = culture.TextInfo;  
  13.             Console.WriteLine(text.ToTitleCase(str));  
  14.             Console.WriteLine(text.ToUpper(str));  
  15.             Console.WriteLine(text.ToLower(str));  
  16.             Console.ReadLine();  
  17.         }  
  18.     }  
  19. }