結果
| 問題 | 
                            No.105 arcの六角ボルト
                             | 
                    
| コンテスト | |
| ユーザー | 
                             mayoko_
                         | 
                    
| 提出日時 | 2014-12-16 23:32:11 | 
| 言語 | C++11(廃止可能性あり)  (gcc 13.3.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 1,091 bytes | 
| コンパイル時間 | 719 ms | 
| コンパイル使用メモリ | 75,972 KB | 
| 実行使用メモリ | 5,248 KB | 
| 最終ジャッジ日時 | 2024-06-11 21:58:59 | 
| 合計ジャッジ時間 | 1,247 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge1 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | WA * 1 | 
ソースコード
#include <sstream>
#include <string>
#include <vector>
#include <map>
#include <algorithm>
#include <iostream>
#include <utility>
#include <set>
#include <cctype>
#include <queue>
#include <stack>
#include <cstdio>
#include <cstdlib>
#include <cmath>
#define INF 1000000000
using namespace std;
typedef long long ll;
int main(void) {
    int T;
    cin >> T;
    while (T--) {
        double x[6];
        double y[6];
        vector<int> candidate;
        for (int i = 0; i < 6; i++) {
            cin >> x[i] >> y[i];
            if (x[i] > 0 && y[i] > 0) candidate.push_back(i);
        }
        if (candidate.size() == 1) {
            double ans = acos(x[candidate[0]]);
            ans = ans / M_PI * 180;
            printf("%.10lf\n", ans);
        } else {
            int index = 0;
            if (x[candidate[0]] > x[candidate[1]]) index = 0;
            else index = 1;
            double ans = acos(x[candidate[index]]);
            ans = ans / M_PI * 180;
            printf("%.10lf\n", ans);
        }
    }
    return 0;
}
            
            
            
        
            
mayoko_