wu :: forums
« wu :: forums - Imp Riddle »

Welcome, Guest. Please Login or Register.
May 18th, 2024, 4:33pm

RIDDLES SITE WRITE MATH! Home Home Help Help Search Search Members Members Login Login Register Register
   wu :: forums
   riddles
   easy
(Moderators: towr, SMQ, Icarus, william wu, Grimbal, ThudnBlunder, Eigenray)
   Imp Riddle
« Previous topic | Next topic »
Pages: 1  Reply Reply Notify of replies Notify of replies Send Topic Send Topic Print Print
   Author  Topic: Imp Riddle  (Read 2300 times)
Ela
Newbie
*






   


Gender: female
Posts: 25
Imp Riddle  
« on: Jul 18th, 2012, 11:10pm »
Quote Quote Modify Modify

Roll Eyes
In a town of imps there are 1,000 residents.
At dusk, the first resident has turned the switch 'ON'  
to 1,000 lamps, right after him came the second imp,
and turned off every second light. right after him the third imp
started to turn off every light that was on
and turning 'on' every light that was 'off' just if  
it was a lump number that is divided by 3.
 and so on for the forth.... fifth.....  untill the last resident.
 
Q: After the last resident in imp Town , finish his duties, how many lamps stayed lighten ?
 
explain your answer.
IP Logged
rmsgrey
Uberpuzzler
*****





134688278 134688278   rmsgrey   rmsgrey


Gender: male
Posts: 2873
Re: Imp Riddle  
« Reply #1 on: Jul 19th, 2012, 5:35am »
Quote Quote Modify Modify

There's a version of this somewhere around here already - with a mad gaoler and 100 prison cells.
 
The answer is:
 
hidden:
The lamps whose number has an odd number of factors will be lit, ie those with numbers that are perfect squares
IP Logged
Ela
Newbie
*






   


Gender: female
Posts: 25
Re: Imp Riddle  
« Reply #2 on: Jul 19th, 2012, 6:17am »
Quote Quote Modify Modify

that's close. but not the answer
i need an exact answer with a reason. Grin
IP Logged
rmsgrey
Uberpuzzler
*****





134688278 134688278   rmsgrey   rmsgrey


Gender: male
Posts: 2873
Re: Imp Riddle  
« Reply #3 on: Jul 20th, 2012, 4:11am »
Quote Quote Modify Modify

Okay: 31
 
Reason: because I said so!
IP Logged
towr
wu::riddles Moderator
Uberpuzzler
*****



Some people are average, some are just mean.

   


Gender: male
Posts: 13730
Re: Imp Riddle  
« Reply #4 on: Jul 20th, 2012, 8:46am »
Quote Quote Modify Modify

I liked the first reason better Tongue
 
Another reason:
Python Code:
a = [];
for i in range(1000):
  a.append(0);
 
for i in range (1, 1001):
  for j in range (1, 1001):
    if j % i == 0:
     a[j-1] = 1 - a[j-1];
sum(a)

Which gives the same answer.
« Last Edit: Jul 20th, 2012, 8:47am by towr » IP Logged

Wikipedia, Google, Mathworld, Integer sequence DB
0.999...
Full Member
***





   


Gender: male
Posts: 156
Re: Imp Riddle  
« Reply #5 on: Jul 20th, 2012, 7:22pm »
Quote Quote Modify Modify

I got a different answer when I tried it on my string of 1000 "Christmas" lights.
IP Logged
towr
wu::riddles Moderator
Uberpuzzler
*****



Some people are average, some are just mean.

   


Gender: male
Posts: 13730
Re: Imp Riddle  
« Reply #6 on: Jul 21st, 2012, 1:52am »
Quote Quote Modify Modify

Really? On the third round, how did you turn on the sixth light?
IP Logged

Wikipedia, Google, Mathworld, Integer sequence DB
0.999...
Full Member
***





   


Gender: male
Posts: 156
Re: Imp Riddle  
« Reply #7 on: Jul 21st, 2012, 5:35am »
Quote Quote Modify Modify

By "it" I mean the version of the riddle that follows from me misreading the text.
IP Logged
Ela
Newbie
*






   


Gender: female
Posts: 25
Re: Imp Riddle  
« Reply #8 on: Jul 22nd, 2012, 1:00am »
Quote Quote Modify Modify

Thanks! Cool
IP Logged
Pages: 1  Reply Reply Notify of replies Notify of replies Send Topic Send Topic Print Print

« Previous topic | Next topic »

Powered by YaBB 1 Gold - SP 1.4!
Forum software copyright © 2000-2004 Yet another Bulletin Board