Jey Balachandran Jey Balachandran - 5 months ago 56
Javascript Question

JavaScript triple greater than

I saw this syntax on another StackOverflow post and was curious as to what it does:

var len = this.length >>> 0;

What does

Joe Joe

That's an unsigned right shift operator. Interestingly, it is the only bitwise operator that is unsigned in JavaScript.

The >>> operator shifts the bits of expression1 right by the number of bits specified in expression2. Zeroes are filled in from the left. Digits shifted off the right are discarded.