24 ms·Because Math.random's expensive and you don't want to execute it unless you're sure.by aquarion 13y agoBecause Math.random's expensive and you don't want to execute it unless you're sure.drharris 13y agoExpensive only really matters in a loop. And this logical operator would short circuit anyway.masklinn 13y agoThe && operator short-circuits, if `!_ok` Math.random won't be called at all.