What is the difference between string and String in C# ?
Both are same and string keyword is an alias for String class.
string is a primitive type defined in C# language and is converted into String during compilation.
string is mutable and String is immutable.
None of the above.
For understanding difference between string and String open visual studio and type string variable then right click on string and click on go to definition option. you will observe that it will open code definition which appears like public class String. It means that string is converted into String during compilation .
Back To Top