The diameter of a binary tree is the number of edges on the longest path between any two nodes; it need not pass through the root. Return the diameter. Input format Level-order JSON array with nulls, e.g. [[1,2,3,4,5]] . TreeNode is predefined.