Stories, Tutorials
& Life Tips
Deep dives on coding, health, recipes, travel and everything in between.
π Explore Reading Paths
Follow curated journeys from beginner to expert
Sum of Root To Leaf Binary Numbers - Tree - Easy - LeetCode
You are given the root of a binary tree where each node has a value 0 or 1. Each root-to-leaf path represents a binary number starting with the most significant bit. For example, if the paβ¦
Cousins in Binary Tree - Tree - Easy - LeetCode
In a binary tree, the root node is at depth 0, and children of each depth k node are at depth k+1. Two nodes of a binaryβ¦
Univalued Binary Tree - Tree - Easy - LeetCode
A binary tree is univalued if every node in the tree has the same value. Return true if and only if the given tree is unβ¦
Range Sum of BST - Tree - Easy - LeetCode
Given the root node of a binary search tree, return the sum of values of all nodes with value between L and R (inclusiveβ¦
Increasing Order Search Tree - Tree - Easy - LeetCode
Given a binary search tree, rearrange the tree in in-order so that the leftmost node in the tree is now the root of the β¦
Leaf-Similar Trees - Tree - Easy - LeetCode
Consider all the leaves of a binary tree, from left to right order, the values of those leaves form a leaf value sequencβ¦
Minimum Distance Between BST Nodes - Tree - Easy - LeetCode
Given a Binary Search Tree (BST) with the root node root, return the minimum difference between the values of any two diβ¦
Search in a Binary Search Tree - Tree - Easy - LeetCode
Given the root node of a binary search tree (BST) and a value. You need to find the node in the BST that the node's valuβ¦
Longest Univalue Path - Tree - Easy - LeetCode
Given a binary tree, find the length of the longest path where each node in the path has the same value. This path may oβ¦
Second Minimum Node In a Binary Tree - Tree - Easy - LeetCode
Given a non-empty special binary tree consisting of nodes with the non-negative value, where each node in this tree has β¦
Trim a Binary Search Tree - Tree - Easy - LeetCode
Given the root of a binary search tree and the lowest and highest boundaries as low and high, trim the tree so that all β¦
Two Sum IV - Input is a BST - Tree - Easy - LeetCode
Given the root of a Binary Search Tree and a target number k, return true if there exist two elements in the BST such thβ¦
Average of Levels in Binary Tree - Tree - Easy - LeetCode
Given a non-empty binary tree, return the average value of the nodes on each level in the form of an array.Example 1:Inpβ¦
Merge Two Binary Trees - Tree - Easy - LeetCode
Given two binary trees and imagine that when you put one of them to cover the other, some nodes of the two trees are oveβ¦
Construct String from Binary Tree - Tree - Easy - LeetCode
You need to construct a string consists of parenthesis and integers from a binary tree with the preorder traversing way.β¦