結果
| 問題 | No.236 鴛鴦茶 |
| コンテスト | |
| ユーザー |
testestest
|
| 提出日時 | 2015-08-09 13:14:43 |
| 言語 | C90(gcc12) (gcc 12.4.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 111 bytes |
| 記録 | |
| コンパイル時間 | 99 ms |
| コンパイル使用メモリ | 28,996 KB |
| 最終ジャッジ日時 | 2026-02-23 19:10:40 |
|
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 2 |
| other | WA * 23 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:3:1: warning: incompatible implicit declaration of built-in function ‘scanf’ [-Wbuiltin-declaration-mismatch]
3 | scanf("%d%d%d%d",&a,&b,&c,&d);
| ^~~~~
main.c:1:1: note: include ‘<stdio.h>’ or provide a declaration of ‘scanf’
+++ |+#include <stdio.h>
1 | int main(){
main.c:4:1: warning: incompatible implicit declaration of built-in function ‘printf’ [-Wbuiltin-declaration-mismatch]
4 | printf("%d",b*c>a*d?d+d*a*1./b:c+c*b*1./a);
| ^~~~~~
main.c:4:1: note: include ‘<stdio.h>’ or provide a declaration of ‘printf’
main.c:4:10: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘double’ [-Wformat=]
4 | printf("%d",b*c>a*d?d+d*a*1./b:c+c*b*1./a);
| ~^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| | |
| int double
| %f
ソースコード
int main(){
int a,b,c,d;
scanf("%d%d%d%d",&a,&b,&c,&d);
printf("%d",b*c>a*d?d+d*a*1./b:c+c*b*1./a);
return 0;
}
testestest