What can happen if you modify a List in Java while iterating through it in another thread?
Interview Answers
Anonymous
Nov 2, 2017
concurrentmodificationexception
Anonymous
Jan 25, 2017
Didn't know the answer so I described what would happen if the Java standard library had not any protections. Actually, Java will throw an Exception. Explained a way Java can recognize the concurrent access and throw the exception. Interviewer explained how Java implements it actually.