Блог пользователя CSU

Автор CSU, история, 6 лет назад, По-английски

Sometimes, I find binary search/ two pointer as problem tag after finishing the Codeforces round.. But in contest time I could not able to figure out it as binary search /two pointer... Though I guess that the problem may be BS/2 pointer ,I don't understand how to use here BS/ 2 pointer ... So, Could I have any helpful tutorial or anything to solve these type of problems, please?

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

»
6 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Solve more problems.

And give yourself more time to think about a problem. This way you will train your intuition about what ideas are applicable and how. Or read editorials but make sure you are not reading them prematurely.

By the way what is "two pointers" anyway? To me it just seems like a loose collection of very different ideas, joined together by only the fact that there are two pointers somewhere. Query problems with Mo's algorithm and finding the largest triangle rooted at a fixed vertex in a convex polygon have almost nothing to do with each other. Yet, both may be classified as "two pointers"...