diff --git a/Koko Eating Bananas - Leetcode 875/Koko Eating Bananas - Leetcode 875.py b/Koko Eating Bananas - Leetcode 875/Koko Eating Bananas - Leetcode 875.py index aee204b..557b949 100644 --- a/Koko Eating Bananas - Leetcode 875/Koko Eating Bananas - Leetcode 875.py +++ b/Koko Eating Bananas - Leetcode 875/Koko Eating Bananas - Leetcode 875.py @@ -4,7 +4,8 @@ def k_works(k): hours = 0 for p in piles: - hours += ceil(p / k) + # hours += ceil(p / k) ## may not work as expected without explicitly importing math.ceil + hours += ceil(p / k - 1) // k return hours <= h