結果
| 問題 | No.338 アンケート機能 | 
| コンテスト | |
| ユーザー |  | 
| 提出日時 | 2016-01-30 01:57:34 | 
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) | 
| 結果 | 
                                RE
                                 
                             | 
| 実行時間 | - | 
| コード長 | 909 bytes | 
| コンパイル時間 | 664 ms | 
| コンパイル使用メモリ | 87,140 KB | 
| 実行使用メモリ | 6,944 KB | 
| 最終ジャッジ日時 | 2024-09-21 18:57:08 | 
| 合計ジャッジ時間 | 2,750 ms | 
| ジャッジサーバーID (参考情報) | judge1 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 19 RE * 9 | 
ソースコード
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cctype>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <utility>
#include <vector>
#define REP(i,s,n) for(int i=(int)(s);i<(int)(n);i++)
using namespace std;
typedef long long int ll;
typedef vector<int> VI;
typedef pair<int, int> PI;
const double EPS=1e-9;
int main(void){
	int a, b;
    cin >> a >> b;
    REP(n, 1, 201) {
        int x = (2 * a + 1) * n / 200;
        int ta = (200 * x + n) / n / 2;
        int tb = (200 * (n - x) + n) / n / 2;
        if (ta == a && tb == b) {
            cout << n << endl;
            return 0;
        }
    }
    assert(0);
}
            
            
            
        