When two threads access the same ArrayList object what is the outcome of the program?
(a) Both are able to access the object
(b) ConcurrentModificationException is thrown
(c) One thread is able to access the object and second thread gets Null Pointer exception
(d) One thread is able to access the object and second thread will wait till control is passed to the second one
This question was addressed to me during a job interview.
I need to ask this question from Data Structures-List in chapter java.util – The Collections Framework of Java
Select the correct answer from above options
Java questions and answers, Java questions pdf, Java question bank, Java questions and answers pdf, mcq on Java pdf, Java questions and solutions, Java mcq Test , Interview Java questions, Java Questions for Interview, Java MCQ (Multiple Choice Questions),Core Java Questions, Core Java MCQ,core java interview questions for experiencedcore java interview questions for 3 years experience,java programming questions,core java interview questions for freshers,java interview questions and answers for freshers, java programming questions and answers pdf, java interview questions for beginners