結果
問題 | No.301 サイコロで確率問題 (1) |
ユーザー | testestest |
提出日時 | 2016-06-01 00:20:53 |
言語 | C90 (gcc 11.4.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 95 bytes |
コンパイル時間 | 299 ms |
コンパイル使用メモリ | 20,480 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-10-08 01:30:34 |
合計ジャッジ時間 | 890 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
コンパイルメッセージ
main.c:1:1: warning: data definition has no type or storage class 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} | ^ main.c:1:1: warning: type defaults to ‘int’ in declaration of ‘i’ [-Wimplicit-int] main.c:1:3: warning: return type defaults to ‘int’ [-Wimplicit-int] 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} | ^~~~ main.c: In function ‘main’: main.c:1:3: warning: type of ‘n’ defaults to ‘int’ [-Wimplicit-int] main.c:1:15: warning: implicit declaration of function ‘gets’ [-Wimplicit-function-declaration] 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} | ^~~~ main.c:1:27: warning: implicit declaration of function ‘scanf’ [-Wimplicit-function-declaration] 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} | ^~~~~ main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ +++ |+#include <stdio.h> 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} main.c:1:27: warning: incompatible implicit declaration of built-in function ‘scanf’ [-Wbuiltin-declaration-mismatch] 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} | ^~~~~ main.c:1:27: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’ main.c:1:42: warning: implicit declaration of function ‘printf’ [-Wimplicit-function-declaration] 1 | i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));} | ^~~~~~ main.c:1:42: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’ main.c:1:42: warning: incompatible implicit de
ソースコード
i;main(n){for(gets(&n);i=~scanf("%d",&n);printf("%f\n",n>13?n+1.66:n<7?6:n*n/9.-n*1.4+14.36));}