If x is 0, 0 is printed. If y is 0, we get an error.
Why is this? The only thing I can think of is that the order in which the Boolean expression is compiled matters. If x is 0 then we get (false)&&(error value) where false is on the left side, and if y is 0 then we get (error value)&&(false). Why does this effect what is printed?
int main(void) {
int x = 1;
int y = 0;
int a = (x/y > 0)&&(y/x > 0);
printf("%d\n", a);
return 0;
}