-
When two threads access the same ArrayList object what is the outcome of the program?
-
- One thread is able to access the object and second thread will wait till control is passed to the second one
- One thread is able to access the object and second thread gets Null Pointer exception
- Both are able to access the object
- ConcurrentModificationException is thrown
- None of these
Correct Option: D
ArrayList is not synchronized. Vector is the synchronized data structure.