Wednesday, 23 April 2014

what is difference between String and StringBuilder

String :
  • String is the Immutable.
  • Data value may not be changed and variable value may be changed.
  • We can use the memory  size is cannot be increased.
  • Namespace of the String is System.Text.
StringBuilder :
  • StringBuilder is mutable.
  • Data value may be changed and also variable value may be changed.
  • Which we can used for memory size is can be increased like append, insert and etc......
  • StringBuilder is faster than Strings.
  • NameSpace of the StringBuilder is System.Text.StringBuilder.

No comments:

Post a Comment