#543

Diameter of Binary Tree

easy· Treesruns: 0

Given the root of a binary tree, return the length of the diameter of the tree. The diameter is the length (in edges) of the longest path between any two nodes in the tree. This path may or may not pass through the root.

sign in to paste and practice your own solution
desktop only

codedrill is a typing game and needs a real keyboard. open this on a laptop or desktop to practice.

you can still browse problems and sections from your phone.