Which data structure is used to implement depth-first search (DFS) of a graph?

PYQ CoCubes 2025

Which data structure is used to implement depth-first search (DFS) of a graph?

  1. A.

    Queue

  2. B.

    Stack

  3. C.

    LinkedList

  4. D.

    None of the above

Attempted by 1182 students.

Sign up free to check your answer

Sign up free

Explore the full course: Cdac C Cat Complete Preparation

Loading lesson…