2.06 Tree

Tree #

No.TitleSolutionDifficultyTimeComplexitySpaceComplexityFavoriteAcceptance
0094Binary Tree Inorder TraversalGoEasyO(n)O(1)72.0%
0095Unique Binary Search Trees IIGoMedium50.9%
0096Unique Binary Search TreesGoMediumO(n^2)O(n)59.0%
0098Validate Binary Search TreeGoMediumO(n)O(1)31.5%
0099Recover Binary Search TreeGoMediumO(n)O(1)49.8%
0100Same TreeGoEasyO(n)O(1)56.1%
0101Symmetric TreeGoEasyO(n)O(1)52.5%
0102Binary Tree Level Order TraversalGoMediumO(n)O(1)62.8%
0103Binary Tree Zigzag Level Order TraversalGoMediumO(n)O(n)54.7%
0104Maximum Depth of Binary TreeGoEasyO(n)O(1)72.8%
0105Construct Binary Tree from Preorder and Inorder TraversalGoMedium60.1%
0106Construct Binary Tree from Inorder and Postorder TraversalGoMedium56.8%
0107Binary Tree Level Order Traversal IIGoMediumO(n)O(1)59.8%
0108Convert Sorted Array to Binary Search TreeGoEasyO(n)O(1)68.4%
0109Convert Sorted List to Binary Search TreeGoMedium56.8%
0110Balanced Binary TreeGoEasyO(n)O(1)47.8%
0111Minimum Depth of Binary TreeGoEasyO(n)O(1)43.2%
0112Path SumGoEasyO(n)O(1)46.4%
0113Path Sum IIGoMediumO(n)O(1)55.1%
0114Flatten Binary Tree to Linked ListGoMediumO(n)O(1)60.6%
0116Populating Next Right Pointers in Each NodeGoMedium58.8%
0124Binary Tree Maximum Path SumGoHardO(n)O(1)38.2%
0129Sum Root to Leaf NumbersGoMediumO(n)O(1)58.1%
0144Binary Tree Preorder TraversalGoEasyO(n)O(1)64.0%
0145Binary Tree Postorder TraversalGoEasyO(n)O(1)65.8%
0173Binary Search Tree IteratorGoMediumO(n)O(1)68.5%
0199Binary Tree Right Side ViewGoMediumO(n)O(1)60.9%
0222Count Complete Tree NodesGoMediumO(n)O(1)56.8%
0226Invert Binary TreeGoEasyO(n)O(1)72.8%
0230Kth Smallest Element in a BSTGoMediumO(n)O(1)68.8%
0235Lowest Common Ancestor of a Binary Search TreeGoEasyO(n)O(1)59.6%
0236Lowest Common Ancestor of a Binary TreeGoMediumO(n)O(1)57.5%
0257Binary Tree PathsGoEasyO(n)O(1)60.0%
0297Serialize and Deserialize Binary TreeGoHard54.6%
0331Verify Preorder Serialization of a Binary TreeGoMedium44.0%
0337House Robber IIIGoMedium53.7%
0341Flatten Nested List IteratorGoMedium61.3%
0404Sum of Left LeavesGoEasyO(n)O(1)55.9%
0429N-ary Tree Level Order TraversalGoMedium69.3%
0437Path Sum IIIGoMediumO(n)O(1)49.3%
0508Most Frequent Subtree SumGoMedium63.9%
0513Find Bottom Left Tree ValueGoMedium66.1%
0515Find Largest Value in Each Tree RowGoMediumO(n)O(n)64.6%
0530Minimum Absolute Difference in BSTGoEasy56.6%
0538Convert BST to Greater TreeGoMedium67.0%
0543Diameter of Binary TreeGoEasy55.5%
0559Maximum Depth of N-ary TreeGoEasy71.4%
0563Binary Tree TiltGoEasy59.1%
0572Subtree of Another TreeGoEasy45.8%
0589N-ary Tree Preorder TraversalGoEasy76.3%
0617Merge Two Binary TreesGoEasy78.4%
0623Add One Row to TreeGoMedium54.2%
0637Average of Levels in Binary TreeGoEasyO(n)O(n)69.3%
0653Two Sum IV - Input is a BSTGoEasy59.3%
0662Maximum Width of Binary TreeGoMedium40.4%
0669Trim a Binary Search TreeGoMedium66.3%
0700Search in a Binary Search TreeGoEasy76.9%
0701Insert into a Binary Search TreeGoMedium74.7%
0703Kth Largest Element in a StreamGoEasy55.3%
0783Minimum Distance Between BST NodesGoEasy56.6%
0834Sum of Distances in TreeGoHard53.8%
0863All Nodes Distance K in Binary TreeGoMedium61.9%
0872Leaf-Similar TreesGoEasy65.1%
0897Increasing Order Search TreeGoEasy78.4%
0938Range Sum of BSTGoEasy85.3%
0958Check Completeness of a Binary TreeGoMedium53.8%
0968Binary Tree CamerasGoHard46.8%
0971Flip Binary Tree To Match Preorder TraversalGoMedium49.9%
0979Distribute Coins in Binary TreeGoMedium71.9%
0987Vertical Order Traversal of a Binary TreeGoHard42.2%
0993Cousins in Binary TreeGoEasyO(n)O(1)54.0%
1022Sum of Root To Leaf Binary NumbersGoEasy73.8%
1026Maximum Difference Between Node and AncestorGoMedium73.3%
1028Recover a Tree From Preorder TraversalGoHard72.7%
1038Binary Search Tree to Greater Sum TreeGoMedium85.2%
1104Path In Zigzag Labelled Binary TreeGoMedium74.8%
1110Delete Nodes And Return ForestGoMedium69.3%
1123Lowest Common Ancestor of Deepest LeavesGoMedium70.4%
1145Binary Tree Coloring GameGoMedium51.4%
1302Deepest Leaves SumGoMedium87.0%
1305All Elements in Two Binary Search TreesGoMedium79.7%
1600Throne InheritanceGoMedium63.7%
1609Even Odd TreeGoMedium53.4%
2096Step-By-Step Directions From a Binary Tree Node to AnotherGoMedium48.9%
——————————————————————-——-—————-—————————-————-————-

⬅️上一页

下一页➡️

Calendar Sep 11, 2022
Edit Edit this page
本站总访问量:  次 您是本站第  位访问者