1190. Smallest Common Region

Medium
Array
Hash Table
String
Tree
Depth-First Search
Breadth-First Search
Binary Lifting
Lowest Common Ancestor

Description

Hints

Hint 1
Try to model the problem as a graph problem.
Hint 2
The given graph is a tree.
Hint 3
The problem is reduced to finding the lowest common ancestor of two nodes in a tree.

Statistics

Acceptance
68.8%
Submissions
59,681
Accepted
41,077