4 ms·
let mid = Math.floor((low + high) / 2); I don't know if JS has the same problem with overflow, but seeing that expression always reminds me of https://news.yco
by userbinator 7y ago
let mid = Math.floor((low + high) / 2);
I don't know if JS has the same problem with overflow, but seeing that expression always reminds me of https://news.ycombinator.com/item?id=14906429 https://news.ycombinator.com/item?id=14906429
- dsego 7y agoJS only has 64-bit floats.