Bifalgorithm post · Brisk · Chapter 1

How can swapping Zoe and Wash fix the tree?

How can swapping Zoe and Wash fix the tree? (Brisk · Chapter 1) — "Many ways; one would be to swap Zoe ’s and Wash ’s positions. If we do that, the fixed tree…

Ideas in this flowchart

  • Obtaining a fixed tree by swapping Zoe’s and Wash’s positions
  • This is one of many possible methods.
  • Swap Zoe’s and Wash’s positions.
  • The swap produces a new fixed tree.
  • The fixed tree is listed as Mal, Jayne, Inara, Kaylee, Zoe, River, Simon, and Wash.
  • Verify that every node of the new tree satisfies the BST property.
Feed/

How can swapping Zoe and Wash fix the tree?

Channel

Brisk

1 page

"Many ways; one would be to swap Zoe ’s and Wash ’s positions. If we do that, the fixed tree would be: Mal Jayne Inara Kaylee Zoe River Simon Wash Take a moment and convince your- self that every node of this new tree does in fact satisfy the BST property."

Flowchart preview
Series cover
👍
0
0 comments0 shares

Sign in to view and post comments.