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?
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.
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.