0
What will be the output of the following code?
#include <stdio.h>
int main() {
int x = -1, y = 0, z = 1;
int result = (x > 0) ? x : (y == 0) ? z : y;
printf("%d", result);
return 0;
}- Acompile time error
- B−1
- C1
- D0
Correct answer: C