fork(1) download
  1. #include <stdio.h>
  2. //関数のプロトタイプ宣言
  3. //ここ↓を埋めてね1
  4. double max(double x,double y);
  5. //main関数
  6. int main(void) {
  7. double a,b,c,d;
  8. a=1;
  9. b=3;
  10. c=8;
  11. d=6;
  12. //ここ↓を埋めてね2
  13. printf("%f",max(max(a,b),max(c,d)));
  14.  
  15. return 0;
  16. }
  17.  
  18. //max関数の定義
  19. double max(double x, double y){
  20. //ここ↓を埋めてね3
  21. double m;
  22. m=x;
  23. if(x<y)
  24. m=y;
  25.  
  26. return m;
  27. }
  28.  
  29.  
  30.  
Success #stdin #stdout 0s 5316KB
stdin
Standard input is empty
stdout
8.000000