Skip to content
Problems
Questions
Roles
Skills
Interview
Contest
Leaderboard
More
Problems
Questions
Roles
Skills
Interview
Contest
Leaderboard
More
Home
/
Backend Developer
/
Questions
/
Trees
Backend Developer
Trees questions
10 questions on Trees for backend developers, easiest first.
Easy
4
Edges in a tree with n nodes
easy
What makes a graph a tree
easy
What a segment tree is for
easy
What a Fenwick tree stores
easy
Medium
1
Checking whether a graph is a tree
medium
Hard
5
Answering many LCA queries fast
hard
Binary lifting memory and query cost
hard
Best root for the shortest tree
hard
Sum of distances from every node
hard
Diameter of a tree with two searches
hard