What is the difference between String and string in C# ? | Difference between String and string
What is the difference between String and string in C#? | Difference between String and string Answer: 1) There is no difference between String (capital S) and string in C# 2) String (capital S) is a class in the .NET framework in the System namespace. 3) The fully qualified name is System.String. Whereas, the lower case string is an alias of System.String 4) string is an alias in C# for System.String. 5) So technically, there is no difference. It's like int vs. System.Int32 Description : As far as guidelines, it's generally recommended to use string any time you're referring to an object. string place = “India”; Likewise, I think it's generally recommended to use String if you need to refer specifically to the class. string place = String.Format("Hello {0}!", place); Conclusion: Both are the same.The difference is how you use it. string is for variables String is for calling other String class methods subscription : difference between string and string in c#,difference between string and string,what is string and string in c#,how string is different from string,csharp string and string,string vs. system.string in c,string vs string,system.string vs string,c# course for beginners,string class in c#,c# step by step tutorial for beginners,csharp string introduction,dotnet and c# tutorial,string in c#.net,c# tutorial for beginners,string in c# tutorial #interview #C-sharp-interview #c-sharp #String
Download
0 formatsNo download links available.