Find the bitwise “and” 0110 1101 , 1001 0011
The bitwise and operator (&) compares each bit of the first operand to the corresponding bit of the second operand. If both bits are 1, the corresponding result bit is set to 1. Otherwise, the corresponding result bit is set to 0. It is an equivalent of logical and - conjunction
First two rows is the given strings, third - the resulting string. According to a definition, we should place "1" in the bit if and only if both bits of the given string is equal to one. So, the resulting string is
0000 0001
Comments
Leave a comment