I am trying to solve problems from POI (as I found them to be really interesting and challenging as well) but when I am stuck, I do not have any resources to look into. I also found the yearly books but since they are in Polish I couldn't understand them as the translation is not that good.
So, can someone explain how to solve this problem?
Link — Salad Bar
Also, I wanted to practice and improve by solving all the problems one by one from the POI website but seeing there is very less resource to learn when I get stuck, how would you suggest I go about it? Should I keep asking in forums like Codeforces whenever I get stuck?
Thank You.