Answers for "bit operations in c"

C
0

bitshift c

i = 14; // Bit pattern 00001110
j = i >> 1; // here we have the bit pattern shifted by 1 thus we get 00000111 = 7 which is 14/2
Posted by: Guest on January-04-2021
0

opération bit à bit c

unsigned a = 0xF0F0;
   unsigned b = 0x00FF;
   unsigned c = a & b; /* c == 0000000011110000 soit 0x00F0 */
Posted by: Guest on December-16-2020

Code answers related to "C"

Browse Popular Code Answers by Language