How to use abs in Node.js

1 Answer

0 votes
let a = 17, b = 390;
           
console.log(Math.abs(-9));
           
console.log(Math.abs(a - b));
 
  
  
  
  
/*
run:
 
9
373
    
*/

 



answered Dec 9, 2021 by avibootz

Related questions

...