This theory is part of Premium
The full write-up (worked counting examples, the trap list and the interview playbook) unlocks with a Premium plan, along with every Pro visualizer.
See pricingTwo arrays and two tricks: find with path compression, union by size or rank.
What this asks
Build the two-operation structure: find and union.
A parent array plus the two accelerators, path compression and union by size or rank.
The full write-up (worked counting examples, the trap list and the interview playbook) unlocks with a Premium plan, along with every Pro visualizer.
See pricing