Efficient bit twiddling Methods