Solution (source code)

= Solution

Set $m=\lceil N/k\rceil$, using the <ceiling function>. If no box contains at least $m$ objects, all boxes contain at most $m-1$, so the total number of objects is at most $k(m-1)$. Taking the <contrapositive>, a total greater than $k(m-1)$ forces some box to contain at least $m$ objects. But $m-1<N/k$, hence $k(m-1)<N$. This proves the <generalized pigeonhole principle>: \b[some box contains at least $\lceil N/k\rceil$ objects].