What is the difference between String and string in C#?

Should you be concerned about the difference a capital letter makes with “string” in C#?

By Jeremy McPeak
September 21, 2016
Screenshot from "What is the difference between String and string in C#?" Screenshot from "What is the difference between String and string in C#?"

Despite C# being a case-sensitive language you may have discovered that whether you use “string” or “String,” the outcome is the same. While the choice may be inconsequential, what’s happening under the hood? In this video, C# beginners will learn whether or not they should be concerned about the difference a capital letter makes. Jeremy McPeak explains the relationship between “System.String” in the .NET framework and string as a C# keyword.

Take your C# skills to the next level with Safari Learning Paths.

Learn faster. Dig deeper. See farther.

Join the O'Reilly online learning platform. Get a free trial today and find answers on the fly, or master something new and useful.

Learn more

Jeremy McPeak is a self-taught programmer who began his career tinkering with websites in 1998. He is the author of Beginning JavaScript, 5th Edition, JavaScript 24-Hour Trainer, and co-author of Professional Ajax, 2nd Edition. He also contributes to Tuts+ Code, providing articles, video tutorials, and courses on JavaScript, C#, ASP.NET, and PHP. He is currently employed by an oil and gas company, building in-house conventional and web applications.

Post topics: Software Engineering
Post tags: Questions
Share: