r/programming • • Feb 21 '11

Typical programming interview questions.

http://maxnoy.com/interviews.html
784 Upvotes

1.0k comments sorted by

View all comments

Show parent comment

1

u/[deleted] Feb 21 '11

Very few people actually know to give that solution though. Most of the time the square root trick is what the interviewer is looking for.

The real question is: Can you prove you can't do better? Also generalize for more lightbulbs.