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 ?    24 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

Write a program that takes a 3 digit number n and finds out whether the number 2^n + 1 is prime, or if it is not prime find out its factors

3 Answers  


difference between object file and executable file

0 Answers  


How is a pointer variable declared?

0 Answers  


What is a 'null pointer assignment' error?

0 Answers  


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

0 Answers  






What are global variables and how do you declare them?

0 Answers  


Can we include one C program into another C program if yes how?

7 Answers   Infosys,


Explain the meaning of keyword 'extern' in a function declaration.

0 Answers  


An expression to whose value an operater is applied a) operand b) variable c) constant d) all of the above

0 Answers  


What is a pointer variable in c language?

0 Answers  


Explain how are 16- and 32-bit numbers stored?

0 Answers  


What is the value of uninitialized variable in c?

0 Answers  


Categories