What is the Main difference between String and
StringBuilder and why do we use StringBuilder.
Answer Posted / ashwini choudhari
string class u can't directly the change the string value
and u want to do some manipulation with the string object
then it's give the new memory in stack when u can the do
the manipulation with the string object but in String
Builder class not happened to give the new memory
allocation in stack it just repalcing the some part of
string which u want repalce or appended so that the
performances increases.
Actually String Builder it is referneces type .
| Is This Answer Correct ? | 11 Yes | 8 No |
Post New Answer View All Answers
What is nameof c#?
What are object pooling and connection pooling and difference? Where do we set the Min and Max Pool size for connection pooling?
When should I use static in C#?
Which one is trusted and which one is untrusted?
Is unboxing an implicit conversion?
What is gui in c#?
What is bitwise operator in c#?
What is icollection in c#?
What language do desktop applications use?
What does using system mean in c#?
What is parseexact c#?
Is namespace necessary in c#?
What is class method?
What is the advantage of singleton class?
Why should you override the tostring() method?