---
title: "#binary-tree articles | Hashnode"
description: "Explore 26 articles tagged #binary-tree on Hashnode. Tutorials, guides, and how-tos from the community."
url: "https://hashnode.com/tag/binary-tree"
---

Tag

# #binary-tree

26 posts · 0 followers

[Min SiThu](https://hashnode.com/@itsmeminsithu) · [1d ago](https://hashnode.com/posts/what-is-a-binary-tree-how-splitting-in-half-finds-anything-fast/6afe604dbeb9a495b922c27a)

### [What Is a Binary Tree? How Splitting in Half Finds Anything Fast](https://itsmeminsithu.hashnode.dev/what-is-a-binary-tree-how-splitting-in-half-finds-anything-fast?utm_source=hashnode&utm_medium=feed)

To put it simply, a binary tree is a way of storing items so that each item points to at most two smaller groups, one holding smaller values on the left and one holding larger values on the right. A p

7 min read · [itsmeminsithu.hashnode.dev](https://itsmeminsithu.hashnode.dev/what-is-a-binary-tree-how-splitting-in-half-finds-anything-fast?utm_source=hashnode&utm_medium=feed)

[Mayank Mahajan](https://hashnode.com/@Mayank9056) · [Sep 25](https://hashnode.com/posts/level-order-traversal-intuition-queue-and-bfs/6ab6f2854b863fc9db1d3f63)

### [Level Order Traversal: Intuition, Queue, and BFS](https://mayankdev.hashnode.dev/level-order-traversal-intuition-queue-and-bfs?utm_source=hashnode&utm_medium=feed)

Understand level order traversal using BFS and queues, with intuition, step-by-step examples, implementation, and complexity.

5 min read · [mayankdev.hashnode.dev](https://mayankdev.hashnode.dev/level-order-traversal-intuition-queue-and-bfs?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/count-good-nodes-in-binary-tree-visualization/69d7d202cbde7a930d4aaec2)

### [LeetCode 1448: Count Good Nodes In Binary Tree — Step-by-Step Visual Trace](https://blog.tracelit.dev/count-good-nodes-in-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

Count the number of ''good'' nodes in a binary tree, where a node is considered good if there are no nodes with a value greater than it in the path from root to that node.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/count-good-nodes-in-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/maximum-depth-of-binary-tree-visualization/69d7d24bb3157a36ebc026d2)

### [LeetCode 104: Maximum Depth Of Binary Tree — Step-by-Step Visual Trace](https://blog.tracelit.dev/maximum-depth-of-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

Given the root of a binary tree, return its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/maximum-depth-of-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/invert-binary-tree-visualization/69d7d2281cf15606b260092e)

### [LeetCode 226: Invert Binary Tree — Step-by-Step Visual Trace](https://blog.tracelit.dev/invert-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

Given the root of a binary tree, invert the tree by swapping the left and right children of every node, and return the root of the inverted tree.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/invert-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/diameter-of-binary-tree-visualization/69d7d20ecbde7a930d4aaeca)

### [LeetCode 543: Diameter Of Binary Tree — Step-by-Step Visual Trace](https://blog.tracelit.dev/diameter-of-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

Find the diameter of a binary tree, which is the length of the longest path between any two nodes in the tree. The path may or may not pass through the root.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/diameter-of-binary-tree-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/construct-binary-tree-from-preorder-and-inorder-traversal-visualization/69d7d1fccbde7a930d4aaebe)

### [LeetCode 105: Construct Binary Tree From Preorder And Inorder Traversal — Step-by-Step Visual Trace](https://blog.tracelit.dev/construct-binary-tree-from-preorder-and-inorder-traversal-visualization?utm_source=hashnode&utm_medium=feed)

Given two arrays representing preorder and inorder traversals of a binary tree, reconstruct and return the original binary tree.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/construct-binary-tree-from-preorder-and-inorder-traversal-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/binary-tree-right-side-view-visualization/69d7d1eef8481628c5175531)

### [LeetCode 199: Binary Tree Right Side View — Step-by-Step Visual Trace](https://blog.tracelit.dev/binary-tree-right-side-view-visualization?utm_source=hashnode&utm_medium=feed)

Given the root of a binary tree, return the values of the nodes you can see ordered from top to bottom when looking at the tree from the right side.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/binary-tree-right-side-view-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/binary-tree-maximum-path-sum-visualization/69d7d1ecf8481628c517552f)

### [LeetCode 124: Binary Tree Maximum Path Sum — Step-by-Step Visual Trace](https://blog.tracelit.dev/binary-tree-maximum-path-sum-visualization?utm_source=hashnode&utm_medium=feed)

Find the maximum sum of any path in a binary tree, where a path is defined as any sequence of nodes connected by parent-child relationships. The path can start and end at any nodes in the tree.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/binary-tree-maximum-path-sum-visualization?utm_source=hashnode&utm_medium=feed)

[tracelit](https://hashnode.com/@tracelit) · [Apr 9](https://hashnode.com/posts/binary-tree-level-order-traversal-visualization/69d7d1ebe06c65e1a004a7bd)

### [LeetCode 102: Binary Tree Level Order Traversal — Step-by-Step Visual Trace](https://blog.tracelit.dev/binary-tree-level-order-traversal-visualization?utm_source=hashnode&utm_medium=feed)

Given the root of a binary tree, return the level order traversal of its nodes'' values as a list of lists, where each inner list contains all node values at that level from left to right.

1 min read · [blog.tracelit.dev](https://blog.tracelit.dev/binary-tree-level-order-traversal-visualization?utm_source=hashnode&utm_medium=feed)
