What will be the output of the following C code? [code] #include <stdio.h> int main() { int x = 2, y = 0; int

Đăng Khánh

New member
What will be the output of the following C code?
Code:
    #include <stdio.h>
    int main()
    {
        int x = 2, y = 0;
        int z = (y++) ? y == 1 && x : 0;
        printf("%d\n", z);
        return 0;
    }
A. 0
B. 1
C. Undefined behaviour
D. Compile time error
 

Tìm kiếm

Back
Top