News for hackers. Stuff that matters.
Re:Write A Function To Determine If A Number Is A Power Of 2 by tyn on Monday October 18, 2010 @12:37PM (#1804138)
Every positive number is a power of 2. Yes, I know, but there is no mention of "integer". Btw, I would just check if log2(x) is an integer.
Re:Write A Function To Determine If A Number Is A Power Of 2 by leif on Monday October 18, 2010 @12:38PM (#1804146)
positive, real
Re:Write A Function To Determine If A Number Is A Power Of 2 by tyn on Monday October 18, 2010 @12:49PM (#1804181)
Right, if you are going to be pedantic, you should go all the way to the end.