what is difference between String buffer and String builder?
Answer Posted / rajujohn
hi All
Both are mutable ,that means we can change value of the
instance variable using append,insert and ...
But only one difference when you go for the multi-thread
concept you use StringBuffer,Because it is thread safe ,that
means, if one thread access this stringbuffer variable on
the time another thread cant access this stringbuffer,so
stringbuffer is slowest performance compare to stringbuilder.
by raju.j
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
what type of questions asked for barclays technologies pune please send urgent
Mention some features of java?
What is role of void keyword in declaring functions?
What is meant by distributed application? Why are we using that in our application?
I want to store more than 10 objects in a remote server? Which methodology will follow?
What are the advantages of exception handling?
How to make a non daemon thread as daemon?
How do you sort arrays in java?
What is polymorphism java example?
Why are the destructors for base class and derived class called in reverse order when the program exits
What mechanism does java use for memory management?
Give differences between Quicksort &Mergesort. When should these sorts be used andwhat is their running time in java?
What is the list interface in java programming?
Objects or references which of them gets garbage collected?
What are the important features of Java 9 release?