The problem statement is not clear at all. I guess codechef just did a google translate from russian to english and posted the question. @admin team, atleast read the translated text and ask yourself if it makes sense before posting it in the website.
Hey gonecase, we will get it checked once again. Meanwhile, can you tell us what confusion are you facing in understanding the problem statement?