Need help with a proof

Revision en2, by divya8080, 2025-06-06 17:45:09

I solved this problem(https://www.codechef.com/problems/SORTSUB7EZ) by using the assumption that:- "all the remainders of ai(wrt any integer) belong to set {0, 1, 2, ....,(ai+1)/2-1}" but idk the proof, can anyone help?

PS: i tried a few values of ai and found out that assumption.

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English divya8080 2025-06-06 17:45:09 21
en1 English divya8080 2025-06-06 17:38:04 300 Initial revision (published)