what is difference between systemstring and


What is difference between System.String and System.StringBuilder classes?

String and StringBuilder classes are used to store string values but the dissimilarity in them is that String is immutable (read only) by nature, because a value once allocated to a String object cannot be changed after its creation. When the value in the String object is modified, a new object is created, in memory, with a new value assigned to the String object. On the other hand, the StringBuilder class is mutable, as it occupies the similar space even if you change the value. The StringBuilder class is more efficient where you have to perform a large amount of string manipulation.

 

Request for Solution File

Ask an Expert for Answer!!
DOT NET Programming: what is difference between systemstring and
Reference No:- TGS0310724

Expected delivery within 24 Hours