tags:

views:

145

answers:

4
int main()
{
 int x = 2, y = 6, z = 6;
 x = y == z;
 printf("%d", x);
}
+3  A: 

== has higher precedence than =, and y==z is 1.

I will end the answer there, because this looks like homework.

Potatoswatter
+2  A: 

http://codepad.org/fp4ZYJX5

Sjoerd
A: 

Output is 1

If you want more help we can give you

ckv
+1  A: 

The output is:

1                                 

Have a look at this, which explains a similar, yet more complex question and will answer yours as well.

phimuemue
+1- I call it time saving tactics.
Praveen S