Hi, is there a way to possibly train our logic for a problem? Sometimes a problem just stumps me, only when I take a quick glance at the editorial after a while of thinking, the solution instantly came up on my mind.
Can anyone give me advice on what I should do at my current level?









I think one thing we should keep in mind is trying our own logic while solving a problem. Editorial is a method of solving the problem by the developer of the problem. Each problem in codeforces is a mental gym for your brain to increase your problem solving skills.Trying new ideas on a problem should be the key goal I guess. However If you are stuck on problem for a long time and you no longer have any new ideas (I mean mentally exhausted). Then you may see the editorial and learn the idea from or take hints from the editorial and immediately code it after understadning logic fully. I reccomend you watching Galen Colin YT videos. He gave me a great advice. Happy problem solving :)
Practice more.