by solacedagony » Fri Jan 05, 2007 11:16 am
I used to code MUD servers in Linux. Actually just dropped my Linux partition when I had to reinstall Windows because I don't use it enough to justify putting aside that disk space.
For those of you who don't know binary, 1=on, 0=off and you read it from right to left. It works in powers of 2's. So the first value, starting from the right, would be equal to 1 if it was on. The next value would be 2. The next 4. Next 8. 16, 32, 64, 128, etc, etc. You figure out which bits are "on" and add up the values they correspond to.
So,
00000001 = 1
00000010 = 2
00000100 = 4
00000101 = 5 (Since we turned the first bit on, which is equal to 1.)
10000000 = 128
10000010 = 130
I used to code MUD servers in Linux. Actually just dropped my Linux partition when I had to reinstall Windows because I don't use it enough to justify putting aside that disk space.
For those of you who don't know binary, 1=on, 0=off and you read it from right to left. It works in powers of 2's. So the first value, starting from the right, would be equal to 1 if it was on. The next value would be 2. The next 4. Next 8. 16, 32, 64, 128, etc, etc. You figure out which bits are "on" and add up the values they correspond to.
So,
00000001 = 1
00000010 = 2
00000100 = 4
00000101 = 5 (Since we turned the first bit on, which is equal to 1.)
10000000 = 128
10000010 = 130