right-to-left-in-place-expansion-pattern

Status: IN

The two-pass right-to-left copy in duplicate-zeros is the same strategy used for merge-sorted-array and similar in-place expansion problems — it avoids O(n) shifting per insertion and O(n) extra space.

Source: entries/2026/06/06/duplicate-zeros-solution.md

JSON