c# why string is immutable
C#. Copy. This creates a string object that contains good morning. Strings are immutable --the contents of a string object cannot be changed after the object is created, although the syntax makes it appear as if you can do this.