Top 50
Topic roadmap
Updated weekly · Last refresh Sep 13

Top 50 traversal Interview Questions

The most frequently asked traversal questions across all roles and companies, ranked by real interview frequency. Updated daily.

50questions
~15htotal time
79companies covered
Track your progressSign up free to work through all 50 questions and resume where you left off.
Start practicing free →
1
bfsStart here. 4 questions · ~71 min
Shortest Paths in Unweighted GraphEasy
Practice

Use BFS to compute shortest path distances from a source node to every node in an unweighted graph.

bfstraversalGraphsUnityNTT DATATelus Digital
Breadth-First Search TraversalEasy
Practice

Return the breadth-first traversal order of a directed HP IQ graph while avoiding repeated visits.

bfstraversalGraphsHp IqMunich Reathenahealth
More bfs questions with a free account
2
dfs7 questions · ~124 min
Cycle Detection in Service GraphMedium
Practice

Detect circular Tencent Cloud TKE service dependencies using DFS node coloring.

dfstraversalGraphsTencentCloud Security ServicesAlten
Depth-First Search TraversalEasy
Practice
Recently asked

Return a deterministic depth-first traversal of an HP IQ directed graph using an explicit stack and cycle detection.

dfstraversalGraphsHp IqManpower Belgium
More dfs questions with a free account

Sign up to see every question

Create a free account to unlock this list and practice real interview questions.

Get my prep plan
3
traversal25 questions · ~443 min
Morris Traversal ImplementationHard
Practice

Return a binary tree's inorder traversal using Morris traversal with O(1) auxiliary space.

traversalAlgorithmsJosh TechnologyJJosh Technology GroupHarness
More traversal questions with a free account
4
More topics14 questions · ~248 min
Longest Path in a DAGHard
Practice
Recently asked

Use topological ordering and dynamic programming to recover the longest dependency pipeline in a directed acyclic graph.

Dynamic ProgrammingtraversalGraphsRAMP Consulting GroupRivian
Reverse Linked List or Detect CyclesMedium
Practice

Detect cycles with Floyd's algorithm, then reverse an acyclic Kraft Heinz product feed linked list in place.

Linked ListstraversalpythonKraft HeinzMilliman
Efficient Traversal of Complex StructuresMedium
Practice

Return the path to a Bloomberg Terminal topic in a nested hierarchy using iterative depth-first search.

efficiencytraversalBloombergEthos Life
More questions with a free account
The finish line: interview-readyComplete all 50 questions to finish this plan.