main()

{

signed int bit=512, mBit;

{

mBit = ~bit;

bit = bit & ~bit ;

printf("%d %d", bit, mBit);

}

}

a. 0, 0

b. 0, 513

c. 512, 0

d. 0, -513

Answers were Sorted based on User's Feedback



main() { signed int bit=512, mBit; { mBit = ~bit; bit = bit & ~bit ; p..

Answer / guest

d)

Is This Answer Correct ?    33 Yes 0 No

main() { signed int bit=512, mBit; { mBit = ~bit; bit = bit & ~bit ; p..

Answer / soni

b

Is This Answer Correct ?    0 Yes 2 No

main() { signed int bit=512, mBit; { mBit = ~bit; bit = bit & ~bit ; p..

Answer / kumaran

a

Is This Answer Correct ?    4 Yes 8 No

Post New Answer

More C Code Interview Questions

How we print the table of 3 using for loop in c programing?

7 Answers  


How can I Create a C program in splitting set of characters to specific subsets. Example: INPUT SET OF CHARACTERS: Therefore, my dear brothers and sisters, stand firm. Let nothing move you. Always give yourselves fully to the work of the Lord, because you know that your labor in the Lord is not in vain. SPLIT INTO HOW MANY CHARACTERS PER SUBSETS: 10 OUTPUT: Therefore, my dear b rothers an d sisters, stand fir m. Let not hing move you. Alway s give you rselves fu lly to the work of t he Lord, b ecause you know that your labo r in the L ord is not in vain.

0 Answers  


Write, efficient code for extracting unique elements from a sorted list of array. e.g. (1, 1, 3, 3, 3, 5, 5, 5, 9, 9, 9, 9) -> (1, 3, 5, 9).

13 Answers   Intel, Microsoft, TCS,


main() { char *p = “ayqm”; printf(“%c”,++*(p++)); }

29 Answers   IBM, TCS, UGC NET, Wipro,


main() { int i=10,j=20; j = i, j?(i,j)?i:j:j; printf("%d %d",i,j); }

2 Answers   Adobe, CSC,


#include<stdio.h> int main() { int a=3,post,pre; post= a++ * a++ * a++; a=3; pre= ++a * ++a * ++a; printf("post=%d pre=%d",post,pre); return 0; }

3 Answers  


main() { int i; clrscr(); printf("%d", &i)+1; scanf("%d", i)-1; } a. Runtime error. b. Runtime error. Access violation. c. Compile error. Illegal syntax d. None of the above

1 Answers   HCL,


how to return a multiple value from a function?

2 Answers   Wipro,


void main() { void *v; int integer=2; int *i=&integer; v=i; printf("%d",(int*)*v); }

1 Answers   Honeywell,


main() { void swap(); int x=10,y=8; swap(&x,&y); printf("x=%d y=%d",x,y); } void swap(int *a, int *b) { *a ^= *b, *b ^= *a, *a ^= *b; }

2 Answers  


main() { int x=5; clrscr(); for(;x<= 0;x--) { printf("x=%d ", x--); } } a. 5, 3, 1 b. 5, 2, 1, c. 5, 3, 1, -1, 3 d. –3, -1, 1, 3, 5

2 Answers   HCL,


main() { char not; not=!2; printf("%d",not); }

1 Answers  


Categories