How do I stop concurrentmodificationexception?
Answer / Digniti Sharma
To avoid ConcurrentModificationException in Java, you can use collections that are thread-safe such as CopyOnWriteArrayList, Vector, or Hashtable. Another solution is to lock the collection while iterating over it using synchronization.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is an abstract class and abstract method?
why an outer class cannot be declared as private?
Describe the Big-O Notation.
What is a classloader in java?
what is mean by ooad? where we are using? can you tell me any real time example?
What is Java Reflection API? Why it’s so important to have?
Is it necessary for the port addresses to be unique? Explain with reason.
What is the difference in between cpp and java? Can u explain in detail?
What is the difference between access specifiers and access modifiers in java?
Which Math method is used to calculate the absolute value of a number?
Program to print 1 1 2 1 2 3 1 2 3 4 like that
These static constructors are correct ? class A { statc intA() { } static A(int x,int y) { } static A(int x) { } }