Hi , i got this problem in codeforces div 2 round and i am not able to understand what it want to do .

any one can help me to figure out the explanation of this problem

problem link

Seems to be a popular question. Check out the discussions already available at: