Skip to content

Instantly share code, notes, and snippets.

@bguiz
Created August 31, 2017 00:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bguiz/97de4bdbfaab1caf037097cf1a28836f to your computer and use it in GitHub Desktop.
Save bguiz/97de4bdbfaab1caf037097cf1a28836f to your computer and use it in GitHub Desktop.
> 0b11111111111111110000000000000000 - 0b100000000000000000
4294770688
> ((0xffff - 2) * 0x10000)
4294770688
> ((0xffff - 2) << 16)
-196608 # WHY??>?
> ((0xffff - 2) << 16) >>> 0
4294770688
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment