Post

 Resources 

Console


Yep... Rag on a Stick (5 replies, 0 views) (2000-Sep-5)
-
Bitshifting will basically divide by 2, or multiply by 2 (multiple times if necessary), it can be used for other stuff, but that is probably the simplest. It works like this, say you have a Byte, like 64, it is represented in binary by this: 01000000 So if we bitshift to the right, what happens is this: 00100000 Or if we go to the left, we get this: 10000000 Now, imagine you are doing this with a number using decimals (Base 10) 55.0 (The 0 makes it easier to understand) If we bitshift in decimal, we are just moving the decimal point, so left would make it 5.50 And right 550.0 So we are just dividing it by 10 (left) or multiplying it by 10 (right) When we work in binary (base 2), the same thing happens, except, instead of being by 10s, it is by 2s (since it is binary). hth


-
Up One Level | Back to Forum

RE: Yep... Corre (4 replies) (2000-Sep-5)
RE: Yep... Almar Joling (3 replies) (2000-Sep-5)
RE: Yep... Corre (2 replies) (2000-Sep-5)
RE: Yep... Jay Wheeler (1 reply) (2000-Sep-5)
RE: Yep... Corre (0 replies) (2000-Sep-6)

Copyright © 2002 - 2004 Eric Coleman, Peter Kuchnio , et. al.
There have been 214 visitors within the last 20 minutes
RSS News Feed