main()
{
int a=4,b=2;
a=b<<a + b>>2;
printf("%d", a);
}

Answers were Sorted based on User's Feedback



main() { int a=4,b=2; a=b<<a + b>>2; printf("%d", a); }..

Answer / shital

ans is :32

Is This Answer Correct ?    23 Yes 1 No

main() { int a=4,b=2; a=b<<a + b>>2; printf("%d", a); }..

Answer / vineetha

tell this answer and mail to this id vachika90@gmail.com

Is This Answer Correct ?    8 Yes 2 No

main() { int a=4,b=2; a=b<<a + b>>2; printf("%d", a); }..

Answer / sanjay bhosale

statement a=b<<a + b>>2;
will be treated as
a=(b<<(a+b))>>2;

and gives output 32.

Is This Answer Correct ?    5 Yes 0 No

main() { int a=4,b=2; a=b<<a + b>>2; printf("%d", a); }..

Answer / a.jayashree

ans is=10;

if its wrong give me right ans to jshree20@gmail.com

Is This Answer Correct ?    0 Yes 2 No

Post New Answer

More C Interview Questions

Why does not c have an exponentiation operator?

0 Answers  


Write a Program to print this triangle: * ** * **** * ****** * ******** * ********** use two nested loops.

12 Answers   MIT, TCS,


What is unary operator?

0 Answers  


wt is d full form of c

6 Answers   TCS, Wipro,


#define FALSE -1 #define TRUE 1 #define NULL 0 main() { if(NULL) puts("NULL"); else if(FALSE) puts("TRUE"); else puts("FALSE"); }

1 Answers  






How does C++ help with the tradeoff of safety vs. usability?

1 Answers  


what is the output on the screen? int n; n=printf("my name is %d",printf("kiran %d",printf("kumar"))); printf("\n %d \n",n);

4 Answers   TCS,


Can a pointer be static?

0 Answers  


Find Index of least significant bit set in an Integer. ex. int value is say 10001000 results should be 4.

1 Answers  


How can I read/write structures from/to data files?

0 Answers  


what does static variable mean?

0 Answers   TCS,


hello freinds next week my interview in reliance,nybody has an idea about it intervew questions..so tell

0 Answers   Reliance,


Categories