#include<stdio.h>
void main()
{
int a,b,c;
a=b=c=1;
c=++a || ++b && ++c;
printf("%d\t%d\t%d",a,b,c);
}

Answers were Sorted based on User's Feedback



#include<stdio.h> void main() { int a,b,c; a=b=c=1; c=++a || ++b && ++c; pri..

Answer / geetha

logical ooperation gives output only 0 or 1 that means
true or false.in this && have higher priority so first
excutes ++b&&++c (1&&1=1)true now 2||1=1.then a value is
incremanted in the ||operation indicates any one operation
excutes only .so a value is incremented and b & c values
are 1 displayed

Is This Answer Correct ?    4 Yes 0 No

#include<stdio.h> void main() { int a,b,c; a=b=c=1; c=++a || ++b && ++c; pri..

Answer / gopinath.j

2 1 1

Is This Answer Correct ?    4 Yes 1 No

#include<stdio.h> void main() { int a,b,c; a=b=c=1; c=++a || ++b && ++c; pri..

Answer / biren

a=2 b=1 c=1
why plz tell me

Is This Answer Correct ?    4 Yes 2 No

Post New Answer

More C Interview Questions

What is difference between scanf and gets?

0 Answers  


why Language C is plateform dependent

3 Answers   Siemens, Wipro,


send me the code of flow chart generator using C-programming language amd this code should calculate the time and space complexity of the given progran and able to generate flowchart according to the given program?

0 Answers   TCS,


what are # pragma staments?

0 Answers  


how i m write c program 1.check prime number 2.prime number series

1 Answers  






Determine the result of performing two successive block transfers into the same area of a frame buffer using the binary arith operations

0 Answers  


what is the output of the following program? #include<stdio.h> void main() { int x=4,y=3,z; z=x-- -y; printf("\n%d %d %d",x,y,z); }

14 Answers  


What functions are used for dynamic memory allocation in c language?

0 Answers  


struct ptr { int a; char b; int *p; }abc; what is d sizeof structure without using "sizeof" operator??

9 Answers   Verifone,


what is a NULL pointer?

2 Answers  


what is associativity explain what is the precidence for * and & , * and ++ how the folloing declaration work 1) *&p; 2) *p++;

0 Answers   L&T,


Can anyone tell what is stack overflow? what precaution we should take?

1 Answers  


Categories