fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. // your code goes here
  5. int a,b,c,d,max;
  6. printf("input a,b,c,d:\n");
  7. scanf("%d,%d,%d,%d",&a,&b,&c,&d);
  8. max=a;
  9. if(b>max) max=b;
  10. if(c>max) max=c;
  11. if(d>max) max=d;
  12. printf("max=%d\n",max);
  13. return 0;
  14. }
  15.  
Success #stdin #stdout 0s 5324KB
stdin
13,15,24,98
stdout
input a,b,c,d:
max=98