PrevNext
Not Frequent
 0/12

Two Pointers

Author: Darren Yao

Iterating two monotonic pointers across an array to search for a pair of indices satisfying some condition in linear time.

StatusSourceProblem NameDifficultyTags
CSESEasy
CSESEasy

Resources

Resources
CPH

solutions to the problems above

IUSACO

above + mention of max subarray sum

CF

video explanation of two pointers

Problems

StatusSourceProblem NameDifficultyTags
CFEasy
Show Tags2P
CSESEasy
Show Tags2P, Sorting
SilverEasy
Show Tags2P, Sorting
CFEasy
Show Tags2P
CFEasy
Show TagsTwo Pointers
SilverNormal
Show Tags2P, Sorting
SilverNormal
Show Tags2P, Sorting
CFNormal
Show Tags2P
CFNormal
Show Tags2P, Greedy, Sorting
CEOIHard
Show Tags2P, Sorting

Module Progress:

Join the USACO Forum!

Stuck on a problem, or don't understand a module? Join the USACO Forum and get help from other competitive programmers!

PrevNext