View Single Post
  #1  
Old 08-22-2009, 07:52 AM
WhiteDragon WhiteDragon is offline
Banned
Join Date: Feb 2007
Posts: 1,002
WhiteDragon is a splendid one to beholdWhiteDragon is a splendid one to beholdWhiteDragon is a splendid one to beholdWhiteDragon is a splendid one to beholdWhiteDragon is a splendid one to behold
Bitwise zero-fill right shift

It'd be nice if I could do this in addition to the other bitwise shifts.

Usually, this is represented by >>>.

I need it for an encryption algorithm I'm currently writing.

Example:

-9 (base 10): 11111111111111111111111111110111 (base 2)
-9 >> 2 (base 10): 11111111111111111111111111111101 (base 2) = -3 (base 10)
-9 >>> 2 (base 10): 00111111111111111111111111111101 (base 2) = 1073741821 (base 10)


It'd be cool if this was done on the current client, or at least v6.

This, and unsigned bitwise shifts, which I already made a thread about awhile back.
Reply With Quote