Fundamentals
/
Tree DP Introduction
⏸
00:00
↻
← Prev
Next →
▶
Question
Given the root of a binary tree, return its diameter (the length of the longest path between any two nodes, measured in edges). Use tree DP.
▶
Understand
▶
Approach
▶
My Code
▶
Reference Solution
Compare
26