Loading algorithms…
Loading visualizer…
Build an optimal prefix-free code by repeatedly merging the two least-frequent nodes. Watch the greedy tree take shape and the codes fall out.
Counted 11 characters → 5 distinct symbols. Each becomes a leaf weighted by its frequency.
Codes appear once the tree is complete.
Type A–Z text or pick a preset · Amber ring = pair being merged · Codes appear once the tree completes
Build an optimal prefix-free code by repeatedly merging the two least-frequent nodes. Watch the greedy tree take shape and the codes fall out.