Working with bits in C