Short Floor (to Integer)

zevanrosser

Zevan Rosser

Posted on October 5, 2021

Short Floor (to Integer)
console.log(~~6.62606889);
console.log(0|6.62606889);
console.log(0^6.62606889);

console.log(Math.floor(6.62606889));
console.log(parseInt(6.62606889,10));
Enter fullscreen mode Exit fullscreen mode

Can you think of any other ways to floor?

💖 💪 🙅 🚩
zevanrosser
Zevan Rosser

Posted on October 5, 2021

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related