Unsigned right shift (>>>): "Unlike the other bitwise operators, zero-fill right shift returns an unsigned 32-bit integer."
Right shift (>>): "The left operand will be converted to a 32-bit integer, which means floating point numbers will be truncated, and number not within the 32-bit bounds will over-/underflow."
Thanks! I will update my code because right shift operators are more understandable to people coming from other languages. My solution using the ~~ operator seems to be very JS-specific :-/
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
>>>): "Unlike the other bitwise operators, zero-fill right shift returns an unsigned 32-bit integer.">>): "The left operand will be converted to a 32-bit integer, which means floating point numbers will be truncated, and number not within the 32-bit bounds will over-/underflow."Thanks! I will update my code because right shift operators are more understandable to people coming from other languages. My solution using the ~~ operator seems to be very JS-specific :-/