1.

Which of this method is used to change an element in a LinkedList Object?(a) change()(b) set()(c) redo()(d) add()This question was posed to me in an internship interview.This intriguing question comes from Java.util in portion java.util – The Collections Framework of Java

Answer»

The CORRECT answer is (b) set()

EASY explanation: An ELEMENT in a LinkedList object can be changed by first using GET() to obtain the index or location of that object and the PASSING that location to method set() along with its new value.



Discussion

No Comment Found

Related InterviewSolutions