fork(1) download
  1. #include <stdio.h>
  2.  
  3. int max(int x, int y);
  4.  
  5. int main(void) {
  6. int a,b,c,d;
  7.  
  8. a = 7;
  9. b = 2;
  10. c = 5;
  11. d = 8;
  12.  
  13. printf("%d\n", max(max(a, b), max(c, d)));
  14.  
  15. return 0;
  16. }
  17.  
  18. int max(int x, int y){
  19.  
  20. if(x>y){
  21. return x;
  22. }
  23. else{
  24. return y;
  25. }
  26. }
Success #stdin #stdout 0s 5316KB
stdin
Standard input is empty
stdout
8