中文
Overview
Posts
98
About
Yosgi
😀
Yosgi
Siqi Liu
A developer who likes to tinker.
Auckland
hiyosgi@gmail.com
RSS Feed
https://www.linkedin.com/in/yosgi/
Nice Resume
A convenient and quick resume builder tool
Our Little Shire
A small 3D village to explore, with stories, animals, and little discoveries
Evo! Partner Expedition
A roguelike creature adventure about building a team, evolving partners, and battling together
Werewolf AI
A Werewolf social-deduction game played with AI players, built on discussion, voting, and hidden roles
Overview
Posts
98
About
28
results for
Binary Tree
Clear filter
222-Number of nodes in a complete binary tree
Counting nodes in a complete binary tree using left/right subtree depths instead of a full DFS.
Algorithms
Created
Sat, 13 Mar 2021 00:00:00 +1300
662-Binary Tree Maximum Width
Computing the maximum width of a binary tree with BFS, tracking each node's position index within its level.
Algorithms
Created
Sat, 13 Mar 2021 00:00:00 +1300
863-All nodes with distance -K- in a binary tree
Finding all nodes at distance K by first adding parent links with DFS, then searching outward from the target.
Algorithms
Created
Sat, 13 Mar 2021 00:00:00 +1300
98-Verify Binary Search Tree
Validating a binary search tree by exploiting the increasing order of its in-order traversal.
Algorithms
Created
Sat, 13 Mar 2021 00:00:00 +1300
99-Restore Binary Search Tree
Restoring a BST with two swapped nodes by locating them during an in-order traversal.
Algorithms
Created
Sat, 13 Mar 2021 00:00:00 +1300
450-Delete a node in a binary search tree
Deleting a node from a binary search tree by locating it via the BST property, then handling the three deletion cases.
Algorithms
Created
Thu, 11 Mar 2021 00:00:00 +1300
669-Pruning a Binary Search Tree
Trimming a BST to a value range by recursing into the correct branch using the BST bounds.
Algorithms
Created
Thu, 11 Mar 2021 00:00:00 +1300
1008-Pre-order traversal to construct a binary search tree
Constructing a binary search tree from its pre-order sequence by recursively inserting each value.
Algorithms
Created
Wed, 10 Mar 2021 00:00:00 +1300
116-Fill in the next right node pointer of each node
Connecting each node to its right neighbor per level, reusing the previous layer's links to reach constant space.
Algorithms
Created
Wed, 10 Mar 2021 00:00:00 +1300
894-All possible full binary trees
Generating all possible full binary trees with recursion that combines left and right subtree counts (DP).
Algorithms
Created
Sun, 07 Mar 2021 00:00:00 +1300
Previous
Next