I've seen this symbol used in math in some javascript functions: >>
I can't find reference to what it means?
The context would be something like:
(a*100)*(b*100) >> 8
I've seen this symbol used in math in some javascript functions: >>
I can't find reference to what it means?
The context would be something like:
(a*100)*(b*100) >> 8
It's a bitwise "Sign-propagating right shift" operator.
Shifts a in binary representation b (< 32) bits to the right, discarding bits shifted off.
Examples:
8 (1000)
8 >> 1 = 4 (0100)
8 >> 2 = 2 (0010)
8 >> 3 = 1 (0001)
8 >> 4 = 0 (0000)