← Problem book: C
Lesson 16 of 96 · 10 XP
Entrance number
Theory and problem statement
Machine translation, not yet reviewed by a native speaker.
Each entrance of a building has k apartments; numbering is continuous, starting from the first entrance.
You are given k and an apartment number n on one line. Which entrance is the apartment in?
Example
Input:
20 1
Output:
1
Sign up for free to solve this task right in your browser: code editor, running, test checks and hints.