GATE IT 2004 · Arrays & Matrix Representation

MCQ · 1 mark · Problem PROG-DSTR-0230

Let P be a singly linked list. Let Q be the pointer to an intermediate node x in the list. What is the worst-case time complexity of the best-known algorithm to delete the node x from the list ?
  1. A
    \(O(n)\)
  2. B
    \(O(\log^2 n)\)
  3. C
    \(O(\log n)\)
  4. D
    \(O(1)\)

Solve it on GATE DA practice →More Basic Data Structures problems

Show the worked solutionOfficial GATE Answer Key: Option A.See full step-by-step discussion on GateOverflow: https://gateoverflow.in/3654/gate2004-it-13

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com