• Home
  • Learn
  • Feed
  • Ladder
  • Saved
← Roadmapsall two pointers & window problems
👉

Two Pointers & Window

Opposite ends, fast/slow, fixed & variable windows.

5 stops · 72 problems0/51 on the path done
next ▸ Valid palindromeSilver · 1120
1

Opposite ends

0/9you are here

Palindrome, two sum sorted, water, 3-sum.

○Valid palindrome○Two sum (sorted)○Reverse vowels of a string○Two Sum II — Sorted Input○Container with most water○Minimum Absolute Difference Pair○Closest Pair Sum○Three sum (count triplets)○Trapping rain water
2

In-place pointers

0/6

Remove duplicates, move, squares, colors.

○Merge Sorted Remove Duplicates○Squares of a sorted array○Sorted Squares Merge○Backspace String Equal○Minimum Window Subsequence○Constrained Subsequence Sum
3

Fixed window

0/4

Size-k sum, average, vowels, anagrams.

○Maximum Sum Subarray of Size K○Max sum of window size k○Maximum Window Sum Size K○Permutation in String
4

Variable window

0/16 of 17

Longest unique, min window, k distinct.

○Max consecutive ones○Longest Substring Without Repeating Characters○Longest Subarray With Sum At Most K○Smallest Subarray With Sum At Least Target○Dedupe Keep At Most Two○Max Consecutive Ones With K Flips○Longest Window Sum At Most○Fruit Into Baskets○Longest Substring With At Most K Distinct○Longest Repeating Character Replacement○Longest Window Values At Most Twice○Substrings Containing All Three Characters○Longest Window K Distinct○Continuous Subarrays○Subarrays With K Distinct Integers○Minimum Window Substring+1 in the arena
5

More Two Pointers & Window

0/16 of 36

Everything else in this category — keep climbing.

○Maximum Sum of a Fixed-Length Window○Sum of Subarray Ranges○Number of Subarrays With Bounded Maximum○Maximum Number of Vowels in a Substring of Length K○Zip Merge Two Arrays○Maximum Average Subarray (Scaled)○Pivot Balance Index○Longest Binary Window With K Zeros○Distinct Pair Sums Inward○Longest Smooth Window○Partition even before odd○Find All Anagram Start Indices○Count Subarrays Summing To Target○Count Pairs Within Distance○Minimum size subarray sum○Count Subarrays With Sum Equals K+20 in the arena
🏁Finish line