Just use & to mask bits and shift right appropriately. If this isn't
enough, please consult a book about bit shifting - I'm not going to
give you an answer for every single possible thing you might want to do
with bit shifting.
Jon Skeet - < XXXX@XXXXX.COM >
If replying to the group, please do not mail me too