結果
| 問題 | 
                            No.538 N.G.S.
                             | 
                    
| コンテスト | |
| ユーザー | 
                             torith
                         | 
                    
| 提出日時 | 2017-07-10 11:20:59 | 
| 言語 | C++11(廃止可能性あり)  (gcc 13.3.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 413 bytes | 
| コンパイル時間 | 1,478 ms | 
| コンパイル使用メモリ | 157,648 KB | 
| 実行使用メモリ | 6,824 KB | 
| 最終ジャッジ日時 | 2024-10-07 06:58:10 | 
| 合計ジャッジ時間 | 2,335 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge1 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 4 | 
| other | AC * 30 WA * 21 | 
ソースコード
/*
 * 538.cpp
 */
//include files
#include<bits/stdc++.h>
using namespace std;
//DEFINE MACROS
#define MIN(a,b) (a>b?b:a)
#define MAX(a,b) (a>b?a:b)
#define PRINTLN(s) cout << s << endl
//DEFINE CONSTANT
//DEFINE PROTOTYPE
int main(){
  int b1,b2,b3;
  double r,d;
  cin >> b1;
  cin >> b2;
  cin >> b3;
  r = (double) (b3 - b2) / (b2 - b1);
  d = b2 - r * b1;
  cout << b3*r + d << "\n";
  return 0;
}
            
            
            
        
            
torith