report VI VI EN
Register | Login
  • HOME
  • PROBLEMSET
  • ROADMAP
  • COMPETITION
  • TOPIC
  • RANKING
  • GUIDE
  • MASHUP
  • ABOUT
  • CONTACT
Module Introduction to two pointers

Introduction to two pointers

**Frequency: 6/10** Help lowering time and memory complexity. In some cases, two pointers can be used instead of binary search.

Resources

- [USACO Guide: Two pointers](https://usaco.guide/silver/two-pointers)

Problems

Merge array 1684 / 1736 800
Brewing potion 2 1463 / 1545 800
Unique elements 1209 / 1288 800
Small range 871 / 959 800
Number of pairs 1106 / 1125 800
Sum of three values 880 / 1011 900
Brewing potion 3 606 / 712 900
Brewing potion 4 544 / 566 900
Three sequences 487 / 498 1000
Biggest submatrix 372 / 399 1100
Choosing numbers 325 / 369 1200

Binary search

  • Introduction to Binary Search
  • Binary search on answer

Two pointers

  • Introduction to two pointers

Math

  • Basic number theory
  • Binary exponentiation

Meet in the middle

  • Introduction to meet in the middle

STL

  • Containers C++ in Standard Template Library (STL)