Answer:
String:
1.String is an class(System.String)
2.String is an Reference type(class)
string:
1.string is an alias name of String class that is created by microsoft
2.string is an value type(data type)
3.string is a C# keyword
4.string is a compiler shortcut for System.String class
As per above points when we use string keyword, it reaches the System.String class and then process accordingly, So we can say that both String and string are same.
Asked In: Many Interviews |
Alert Moderator