Exercise 4: Bitwise Operations
Given the following variable declarations:
signed char x = 0b01010101;
unsigned char y = 0b11001100;
|
What is the value of each of the following expressions:
-
(x & y)
-
(x ^ y)
-
(x << 1)
-
(y << 2)
-
(x >> 1)
-
(y >> 1)
-
(x << 3)
-
(y << 9)
-
(x >> 8)
|