How to round up the result of integer division?
Asked 07 September, 2021
Viewed 1.9K times
  • 66

I'm thinking in particular of how to display pagination controls, when using a language such as C# or Java.

If I have x items which I want to display in chunks of y per page, how many pages will be needed?

16 Answer