C Programming :: Bitwise Operators - Discussion
Home > C Programming > Bitwise Operators > MCQs Questions Discussion
12 / 34
What is the output of the following 'C' program ?
#include <stdio.h>
int main(void)
{
char ch;
int i;
ch = 'd';
ch = ~ch;
for(i=128; i > 0; i = i/2)
if(i&ch)
printf("1");
else
printf("0");
return 0;
}
#include <stdio.h>
int main(void)
{
char ch;
int i;
ch = 'd';
ch = ~ch;
for(i=128; i > 0; i = i/2)
if(i&ch)
printf("1");
else
printf("0");
return 0;
}
A10011011
B11011001
CCompilation Error
DNone of these
Answer: Option (Login/Signup)
Show Explanation
Asked In ::
No Discussion on this question yet!