Re:Collection of classic computer science algorithms written...
by lbolla on Monday June 13, 2011 @10:12AM
(#2649060)
The implementation of the binary_search algorithm (https://github.com/nzakas/computer-science-in-javascript/blo...) is bugged by the infamous (http://googleresearch.blogspot.com/2006/06/extra-extra-read-...) "integer overflow" bug:
[ Parent
| on HN ]
Re:Collection of classic computer science algorithms written...
by Tuna-Fish on Monday June 13, 2011 @11:00AM
(#2649219)
No, it's not. Because JS has no integers -- stopIndex and startIndex are doubles.
Re:Collection of classic computer science algorithms written...
by kenjackson on Monday June 13, 2011 @11:59AM
(#2649494)
So then the less infamous double overflow problem. :-)