Only the changed leaf, its parent, and the root need new hashes.

highlighted = computed this step

Only C, CD, and root need new values

Changing C affects its parent CD and then the root. The AB side stays 0x65.

AB=0x65AB=0x65
Recompute the changed pathA toy Merkle tree recomputes only the affected path.Recompute the changed path - changed root 0froot 0fchanged rootAB 65unchangedA aaunchangedB bbunchangedCD aarecomputedC cdchanged leafD ddunchanged

Recompute CD

Changed CD uses 0xcd and 0xdd, giving 0x1aa and low byte 0xaa.

H(cddd)=0xaaH(cd\Vert dd)=0xaa
Recompute the changed pathA toy Merkle tree recomputes only the affected path.Recompute the changed path - changed root 0froot 0fchanged rootAB 65unchangedA aaunchangedB bbunchangedCD aarecomputedC cdchanged leafD ddunchanged

Recompute the root

The root now uses AB=0x65 and changed CD=0xaa, giving 0x0f.

H(0x650xaa)=0x0fH(0x65\Vert 0xaa)=0x0f
Recompute the changed pathA toy Merkle tree recomputes only the affected path.Recompute the changed path - changed root 0froot 0fchanged rootAB 65unchangedA aaunchangedB bbunchangedCD aarecomputedC cdchanged leafD ddunchanged

Summary

The changed path is C to CD to root.

CCDrootC\to CD\to root
Recompute the changed pathA toy Merkle tree recomputes only the affected path.Recompute the changed path - changed root 0froot 0fchanged rootAB 65unchangedA aaunchangedB bbunchangedCD aarecomputedC cdchanged leafD ddunchanged