結果
| 問題 | No.338 アンケート機能 |
| コンテスト | |
| ユーザー |
Ysmr_Ry
|
| 提出日時 | 2016-03-03 11:18:44 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 374 bytes |
| 記録 | |
| コンパイル時間 | 281 ms |
| コンパイル使用メモリ | 52,020 KB |
| 実行使用メモリ | 7,972 KB |
| 最終ジャッジ日時 | 2026-05-08 10:24:52 |
| 合計ジャッジ時間 | 2,257 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge2_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 28 |
ソースコード
// yukicoder 338 (http://yukicoder.me/problems/814)
#include<cstdio>
#include<algorithm>
#define rep(i,a) for(int i=0;i<(a);++i)
int A, B;
int main()
{
scanf( "%d%d", &A, &B );
int ans = 200;
rep( a, A+1 ) rep( b, B+1 )
{
int s = a+b;
if( A == int(100.0*a/s+0.5) && B == int(100.0*b/s+0.5) )
ans = std::min( ans, s );
}
printf( "%d\n", ans );
return 0;
}
Ysmr_Ry