Question: Take two values a and b in memory and let us generate a new one which satisfies the following: if both a and b have
Take two values a and b in memory and let us generate a new one which satisfies the following: if both a and b have the same value in a particular bit position, then that position in our new value should be a 1, otherwise it is 0. For instance, if a = 0101 and b = 0111 then the new value will be 1101. Which of the following generates our desired value?
OPTIONS: a. ~(a ^ b)
b. a ^ b
c. ~(a | b)
d. ~a | b
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
