java - what's the difference between bitwise shift with 2 arrows and 3 arrows? -


i've seen >> , >>> before. what difference , when use each?

double arrows ">>" , triple arrows ">>>" defined on 32-bit integers, performing these on variable "convert" them so-to-speak non-numbers, numbers. additionally, javascript numbers stored double precision floats, these operations cause lose precision bits higher 32 . ">>" maintains sign bit (result signed integer), while ">>>" not (result unsigned integer).

http://msdn.microsoft.com/en-us/library/342xfs5s%28v=vs.94%29.aspx

for better explanation: https://stackoverflow.com/a/1822769/780399


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -