Take a test Sign in 中文
← Exercise 368 →
Search
Go to
{{searchResults.length}} {{searchResults.length === 1 ? 'result' : 'results'}} for “{{searchWords}}” No results found for “{{searchWords}}” × back to contents
AIME Contents · by chapter
Basic Counting (90)
---- (44)
Probability (91)

Exercises and their solutions

Exercise 368
A bored student walks down a hall that contains a row of closed lockers, numbered 1 to 1000. He opens the locker numbered 1, and then alternates between skipping and opening each locker thereafter. When he reaches the end of the hall, the student turns around and starts back. He opens the first closed locker he encounters, and then alternates between skipping and opening each closed locker thereafter. The student continues wandering back and forth in this manner until every locker is open. What is the number of the last locker he opens?
← Back to Problem 368
Solution
  1. Track the closed lockers after each pass; each pass opens every other closed locker, starting from the end where he is.
  2. After pass 1: $2,4,\dots,1000$ ($500$). Pass 2 starts at $1000$, giving $2,6,\dots,998$ ($250$). Then $6,14,\dots,998$ ($125$); $14,30,\dots,990$ ($62$); $30,62,\dots,990$ ($31$); $62,126,\dots,958$ ($15$); $126,254,\dots,894$ ($7$); $254,510,766$; then only $510$ remains.
  3. So $510$ is opened last.
  4. The answer is $\boxed{510}$.
Search Go to Prev      Next

Contact Us

Thanks! Your message has been sent.
By year
1985 (1 problems)
1984 (1 problems)