Arrays and Linked Lists - Complexity Analysis

Download Q&A
Q. What is the space complexity of an array of size n?
  • A. O(1)
  • B. O(n)
  • C. O(log n)
  • D. O(n^2)
Q. What is the time complexity of appending an element to the end of a dynamic array?
  • A. O(1)
  • B. O(n)
  • C. O(log n)
  • D. O(n^2)
Q. What is the time complexity of finding the maximum element in a linked list?
  • A. O(1)
  • B. O(n)
  • C. O(log n)
  • D. O(n^2)
Q. What is the time complexity of inserting an element at a specific index in an array?
  • A. O(1)
  • B. O(n)
  • C. O(log n)
  • D. O(n^2)
Q. What is the time complexity of reversing a linked list?
  • A. O(1)
  • B. O(n)
  • C. O(log n)
  • D. O(n^2)
Q. What is the time complexity of searching for an element in an unsorted array?
  • A. O(1)
  • B. O(n)
  • C. O(log n)
  • D. O(n^2)
Showing 1 to 6 of 6 (1 Pages)
Soulshift Feedback ×

On a scale of 0–10, how likely are you to recommend The Soulshift Academy?

Not likely Very likely