Problems > Fair Apples > Editorial

Fair Apples — Solution & Editorial

Back to the Problem

N mod K children take the ceiling, the rest take the floor.

Complexity: O(1) or O(log)