Question
Lockers
Our local High School posed the following to High School students:
There are 1000 Lockers in a High School with 1000 students.
The first student opens all lockers.
The second student closes all even number lockers (2,4,6,8...)
The third student toggles every third locker. (Toggle= Close if open or Open if closed)
The fourth student toggles every fourth locker. (4,8,12,...)
The fifth student toggles every fifth locker (5,10,15...)
...
The nth student toggles every nth locker (n,2n,3n...)
This continues until all 1000 students have had a turn.
==================================================
Question 1 : How many lockers are open at the end of this excercise?
Question 2: What is the general answer for N lockers and N students?
There are 1000 Lockers in a High School with 1000 students.
The first student opens all lockers.
The second student closes all even number lockers (2,4,6,8...)
The third student toggles every third locker. (Toggle= Close if open or Open if closed)
The fourth student toggles every fourth locker. (4,8,12,...)
The fifth student toggles every fifth locker (5,10,15...)
...
The nth student toggles every nth locker (n,2n,3n...)
This continues until all 1000 students have had a turn.
==================================================
Question 1 : How many lockers are open at the end of this excercise?
Question 2: What is the general answer for N lockers and N students?

