fork download
  1. #include <stdio.h>
  2.  
  3. int main() {
  4. int x, y, res;
  5.  
  6. printf("x = ");
  7. scanf("%d", &x);
  8. printf("y = ");
  9. scanf("%d", &y);
  10.  
  11. res =(x > 0 && y < 0) ? (x + y) : (x > 0 && y > 1) ? (x/(y-1)) : (x-y);
  12. printf("f(x,y) = %d", res);
  13.  
  14. return 0;
  15. }
Success #stdin #stdout 0s 5280KB
stdin
Standard input is empty
stdout
x = y = f(x,y) = -1279932926