title: Using bitwise OR 0 to floor a number
body: <p>A colleague of mine stumbled upon a method to floor float numbers using a bitwise or:</p>
  
  <pre><code>var a = 13.6 | 0; //a == 13
  </code></pre>
  
  <p>We were talking about it and wondering a few things.</p>
  
  <ul>
  <li>How does it work? Our theory was that using such an operator casts the number to an integer, thus removing the fractional part</li>
  <li>Does it have any advantages over doing <code>Math.floor</code>? Maybe it's a bit faster? (pun not intended)</li>
  <li>Does it have any disadvantages? Maybe it doesn't work in some cases? Clarity is an obvious one, since we had to figure it out, and well, I'm writting this question.</li>
  </ul>
  
  <p>Thanks.</p>