Why ArrayList class is not a synchronized class and why it
is not a thread safe class? explain
Answer Posted / atre sachin
If multiple threads access an ArrayList instance concurrently, and at least one of the threads modifies the list structurally, it must be synchronized externally. (A structural modification is any operation that adds or deletes one or more elements, or explicitly resizes the backing array; merely setting the value of an element is not a structural modification.)
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
In which language java is written?
Is null a string?
How to overcome the exception object reference not set to an instance of object?
Can we use return in constructor?
What is a generic code?
What are the 3 types of loops in java?
What are different types of arrays?
What are the properties of thread?
What is return used for in java?
What is the use of a conditional inclusion statement in Java ?
What is the same as procedures?
What is "this" keyword in java? Explain
what are the disadvantages of indexes in oracle?
What is the inheritance?
What is method in java ?