Skip to content

Glossary: Algorithms Beyond the Basics in JavaScript

Slow and fast pointers

Also written: slow and fast pointer

Two indexes moving the same way through one array: the fast one reads every item and the slow one marks the end of the tidy part. Sam's duplicate order IDs are removed in place this way.

Where the book teaches it

Related terms

Two pointers