2 ms·
Incidentally, as outlined in this Julia FAQ, native machine arithmetic with overflow will deal with this correctly. mid = (lo + hi) >>> 1 https://docs.jul
by FabHK 8y ago
Incidentally, as outlined in this Julia FAQ, native machine arithmetic with overflow will deal with this correctly.
mid = (lo + hi) >>> 1
https://docs.julialang.org/en/v1/manual/faq/index.html#Why-does-Julia-use-native-machine-integer-arithmetic?-1 https://docs.julialang.org/en/v1/manual/faq/index.html#Why-d...
EDIT: legibility