#Can someone test my binary thinking?
4 messages · Page 1 of 1 (latest)
4 messages · Page 1 of 1 (latest)
Say you a number in a register. Being in the register, it is expressed in binary form. My question is this: If the two least significant bits are both set to zero and it is an unsigned number, is it always true that that number is divisible by 4?
I think it is true. Please, convince me I am wrong.
You're correct
Any number divisible by 4 can be written as f * 4. Or f << 2. Which sets the lower two bits to 0.
Sweet thanks~