Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:81.0) Gecko/20100101 Firefox/81.0
Firefox 81
Windows
Desktop
4 years ago
Test name Executions per second
Max min 28294400.0 Ops/sec
abs and % 221630896.0 Ops/sec
Script Preparation code:
AخA
 
this.number = Math.random() * 1000;
Tests:
  • Max min

     
    return Math.max(250, Math.min(750, this.number));
  • abs and %

     
    return Math.abs(this.number % 750)