<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Binary Tree on Jeanphilo Blog</title><link>https://jeanphilogong.github.io/jeanblog/tags/binary-tree/</link><description>Recent content in Binary Tree on Jeanphilo Blog</description><generator>Hugo -- 0.168.0</generator><language>en-us</language><lastBuildDate>Mon, 20 Apr 2026 10:01:46 +0800</lastBuildDate><atom:link href="https://jeanphilogong.github.io/jeanblog/tags/binary-tree/index.xml" rel="self" type="application/rss+xml"/><item><title>Hot100: Binary Tree Maximum Path Sum (Tree DP / Single-Side Gain ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/124-binary-tree-maximum-path-sum/</link><pubDate>Mon, 20 Apr 2026 10:01:46 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/124-binary-tree-maximum-path-sum/</guid><description>A practical guide to LeetCode 124 covering the key design split: return only the best single-side gain upward, while using the full path through the current node to update a global answer.</description></item><item><title>Hot100: Binary Tree Right Side View (Level Order Last-Node Rule ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/199-binary-tree-right-side-view/</link><pubDate>Mon, 20 Apr 2026 10:01:46 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/199-binary-tree-right-side-view/</guid><description>A practical guide to LeetCode 199 covering why the right side view is just the last node of each level, plus two stable solutions: level-order BFS and right-first DFS.</description></item><item><title>Hot100: Construct Binary Tree from Preorder and Inorder Traversal (Indexed Divide-and-Conquer ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/105-construct-binary-tree-from-preorder-and-inorder-traversal/</link><pubDate>Mon, 20 Apr 2026 10:01:46 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/105-construct-binary-tree-from-preorder-and-inorder-traversal/</guid><description>A practical guide to LeetCode 105 covering how preorder chooses the root, how inorder splits the subtrees, and how a hash map plus index recursion reduces reconstruction to O(n).</description></item><item><title>Hot100: Convert Sorted Array to Binary Search Tree (Midpoint Divide-and-Conquer ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/108-convert-sorted-array-to-binary-search-tree/</link><pubDate>Mon, 20 Apr 2026 10:01:46 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/108-convert-sorted-array-to-binary-search-tree/</guid><description>A practical guide to LeetCode 108 covering why the midpoint is the natural root, how sorted order and balance requirements work together, and how to build the BST with stable index recursion.</description></item><item><title>Hot100: Flatten Binary Tree to Linked List (Reverse Preorder Rewiring ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/114-flatten-binary-tree-to-linked-list/</link><pubDate>Mon, 20 Apr 2026 10:01:46 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/114-flatten-binary-tree-to-linked-list/</guid><description>A practical guide to LeetCode 114 covering why the flattened list must follow preorder order and how reverse preorder with a prev pointer gives a stable in-place rewiring strategy.</description></item><item><title>Hot100: Kth Smallest Element in a BST (Inorder Counting / Early Stop ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/230-kth-smallest-element-in-a-bst/</link><pubDate>Mon, 20 Apr 2026 10:01:46 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/230-kth-smallest-element-in-a-bst/</guid><description>A practical guide to LeetCode 230 covering why inorder traversal of a BST is sorted, how to count visits with an explicit stack, and how to stop immediately at the k-th node.</description></item><item><title>Hot100: Diameter of Binary Tree (Tree DP / Height Return ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/543-diameter-of-binary-tree/</link><pubDate>Sun, 19 Apr 2026 15:51:55 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/543-diameter-of-binary-tree/</guid><description>A practical guide to LeetCode 543 covering the key split between returned height and global diameter updates, plus engineering mappings and runnable multi-language implementations.</description></item><item><title>Hot100: Lowest Common Ancestor of a Binary Tree (Postorder Return Semantics ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/236-lowest-common-ancestor-of-a-binary-tree/</link><pubDate>Sun, 19 Apr 2026 15:51:55 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/236-lowest-common-ancestor-of-a-binary-tree/</guid><description>A practical guide to LeetCode 236 covering the return-value meaning in postorder recursion, when the current node becomes the answer, and why a node can be its own ancestor.</description></item><item><title>Hot100: Validate Binary Search Tree (Range Constraints / Inorder ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/98-validate-binary-search-tree/</link><pubDate>Sun, 19 Apr 2026 15:13:19 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/98-validate-binary-search-tree/</guid><description>A practical guide to LeetCode 98 covering ancestor range constraints, why parent-only checks fail, and two stable solutions: recursive bounds and inorder validation.</description></item><item><title>Hot100: Binary Tree Level Order Traversal (BFS / DFS ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/102-binary-tree-level-order-traversal/</link><pubDate>Mon, 16 Mar 2026 13:00:56 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/102-binary-tree-level-order-traversal/</guid><description>A practical guide to LeetCode 102 covering level-by-level BFS, level-size boundaries, DFS depth buckets, and runnable multi-language implementations.</description></item><item><title>Hot100: Symmetric Tree (Mirror Recursion / BFS ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/101-symmetric-tree/</link><pubDate>Mon, 16 Mar 2026 13:00:55 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/101-symmetric-tree/</guid><description>A practical guide to LeetCode 101 covering mirror recursion, pairwise BFS checks, symmetry contracts, and runnable multi-language implementations.</description></item><item><title>Hot100: Same Tree (Synchronous Recursion / BFS ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/100-same-tree/</link><pubDate>Mon, 16 Mar 2026 13:00:54 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/100-same-tree/</guid><description>A practical guide to LeetCode 100 covering synchronous recursion, pairwise BFS validation, structural equivalence, and runnable multi-language implementations.</description></item><item><title>Hot100: Invert Binary Tree (Recursion / BFS ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/226-invert-binary-tree/</link><pubDate>Fri, 06 Mar 2026 17:58:23 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/226-invert-binary-tree/</guid><description>A practical guide to LeetCode 226 covering tree mirroring, recursive left-right swaps, BFS traversal, and engineering mappings.</description></item><item><title>Hot100: Maximum Depth of Binary Tree (DFS / BFS ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/104-maximum-depth-of-binary-tree/</link><pubDate>Fri, 06 Mar 2026 17:58:22 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/104-maximum-depth-of-binary-tree/</guid><description>A practical guide to LeetCode 104 covering the depth definition, recursive DFS, level-order BFS, engineering mappings, and runnable multi-language implementations.</description></item><item><title>Hot100: Binary Tree Inorder Traversal (Recursion / Stack ACERS Guide)</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/94-binary-tree-inorder-traversal/</link><pubDate>Fri, 06 Mar 2026 17:58:21 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/hot100/binary-tree/94-binary-tree-inorder-traversal/</guid><description>A practical guide to LeetCode 94 covering left-root-right traversal, recursion, explicit stacks, engineering mappings, and runnable multi-language implementations.</description></item><item><title>Path Sum III: Prefix Sum + Hash Map Counting Downward Paths (LeetCode 437) ACERS Guide</title><link>https://jeanphilogong.github.io/jeanblog/alg/leetcode/437-path-sum-iii/</link><pubDate>Wed, 04 Feb 2026 16:02:26 +0800</pubDate><guid>https://jeanphilogong.github.io/jeanblog/alg/leetcode/437-path-sum-iii/</guid><description>Count downward paths in a binary tree whose sum equals targetSum in O(n) using prefix sums and a frequency hash map, with derivation, engineering mapping, and multi-language implementations.</description></item></channel></rss>