Home » JAVA Programming » Data Structures » Question
  1. What is the worst case complexity of accessing an element in ArrayList?
    1. O(2)
    2. O(nlogn)
    3. O(n)
    4. O(1)
    5. None of these
Correct Option: D

ArrayList has O(1) complexity for accessing an element in ArrayList. O(n) is the complexity for accessing an element from LinkedList.



Your comments will be displayed only after manual approval.