output of the following prigram

int main()
{
intx,y=10,z=10;
x=(y==z);
cout<<x;
return 0;
}

the ans is = 1. Can anyone explain to me this. ???
10 == 10 is true so it assigns 1 to x.
Topic archived. No new replies allowed.