value | 0 will <i>always</i> return a 32 bit integer.<p>Math.floor(value) can return some weirder values such as: NaN (for anything that isn&#x27;t a number), and Infinity, -Infinity, -0. And Math.floor(-1e-300); is -1 so care needs to be taken with floating values near zero.