
C language
To check for particular bit , whether it is on or off we use "&" (AND) operator. Go through simple example given below,Let consider 8-bit binary number,
Binary(8 bit) = 0000 1101
suppose we want check 3rd bit is on or off(on=1 & off=0), just like this,
0000 1100 (Decimal=13)
...