結果

問題 No.453 製薬会社
コンテスト
ユーザー vjudge1
提出日時 2026-05-18 21:30:31
言語 C++17
(gcc 15.2.0 + boost 1.89.0)
コンパイル:
g++-15 -O2 -lm -std=c++17 -Wuninitialized -DONLINE_JUDGE -o a.out _filename_
実行:
./a.out
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 726 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 6,625 ms
コンパイル使用メモリ 280,332 KB
実行使用メモリ 6,400 KB
最終ジャッジ日時 2026-05-18 21:30:45
合計ジャッジ時間 6,559 ms
ジャッジサーバーID
(参考情報)
judge3_0 / judge1_0
純コード判定待ち
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 4
other AC * 9
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

#include<bits/stdc++.h>
#include<bits/extc++.h>
#define int long long
#define inf 0x3f3f3f3f3f3f3f3f
#define maxn 1234567
#define eps 1e-7
#define mod 1000000007
#define Mod 998244353
#define f(i,a,b) for(int i=a;i<=b;i++)
#define r(i,a,b) for(int i=a;i>=b;i--) 
#define fx(i,a,b,x) for(int i=a;i<=b;i+=x)
#define rx(i,a,b,x) for(int i=a;i>=b;i-=x) 
using namespace std;
using namespace __gnu_cxx;
using namespace __gnu_pbds;
int T;
double c,d;
void solve(){
	scanf("%lf%lf",&c,&d);
	if(7.0/5.0*d-7.0/2.0*c>eps)printf("%.7lf\n",7000.0*c);
	else if(4.0/3.0*c-4.0*d>eps)printf("%.7lf\n",4000.0*d);
	else printf("%.7lf\n",6000.0/13.0*c+34000.0/13.0*d);
}
signed main(){
	T=1;
//	scanf("%lld",&T);
	while(T--)solve();
	return 0;
}
0