結果
| 問題 |
No.236 鴛鴦茶
|
| コンテスト | |
| ユーザー |
くれちー
|
| 提出日時 | 2016-08-28 00:31:18 |
| 言語 | C90 (gcc 12.3.0) |
| 結果 |
AC
|
| 実行時間 | 1 ms / 2,000 ms |
| コード長 | 212 bytes |
| コンパイル時間 | 86 ms |
| コンパイル使用メモリ | 20,736 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-28 13:07:55 |
| 合計ジャッジ時間 | 926 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 23 |
コンパイルメッセージ
main.c: In function ‘main’:
main.c:6:9: warning: ignoring return value of ‘scanf’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
6 | scanf("%lf %lf %lf %lf", &a, &b, &x, &y);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ソースコード
#include <stdio.h>
int main() {
double a, b, x, y;
scanf("%lf %lf %lf %lf", &a, &b, &x, &y);
if (x * (b / a) > y) printf("%.7lf\n", y + y * (a / b));
else printf("%.7lf\n", x + x * (b / a));
return 0;
}
くれちー