TouristVsMessi's blog

By TouristVsMessi, history, 6 years ago, In English

Hello everyone.I learned Segment Tree/Fenwick Tree.Now I can only solve some straightforward problem.Can't solve problems which aren't StraightForward.I need to see the Editorials/Codes.

I gave up after 1/1.5 hours.

Should I continue solve problems with Editorial/Codes?What you did when you first learn them?

  • Vote: I like it
  • +11
  • Vote: I do not like it

»
6 years ago, # |
  Vote: I like it +52 Vote: I do not like it

Solving with editorial/code is fine. But if you later see a similar problem and you can't solve it, maybe it means you didn't understand the first problem enough.

»
6 years ago, # |
  Vote: I like it +1 Vote: I do not like it

That's because you memorized the functions of those DS (i.e. how they work). Don't take those functions literally. Rather, use your brain to think of how the properties of those functions and DS could be used to help you achieve your end goal.