Question: Given the following variables, give the result of each of the following operations (show all 8 bits): int num1 = 0b00110101, num2 = 0b11001010, ans;
Given the following variables, give the result of each of the following operations (show all 8 bits):

int num1 = 0b00110101, num2 = 0b11001010, ans; *A. B. *C. D. ans = num1 & num2; ans = num1 | num2; ans = ~num2; ans = numl num2;
Step by Step Solution
3.45 Rating (155 Votes )
There are 3 Steps involved in it
Lets evaluate the binary operations one by one We have two integer variables num1 and num2 that are ... View full answer
Get step-by-step solutions from verified subject matter experts
