結果
| 問題 | No.105 arcの六角ボルト |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2015-04-02 10:24:53 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 43 ms / 5,000 ms |
| コード長 | 576 bytes |
| 記録 | |
| コンパイル時間 | 407 ms |
| コンパイル使用メモリ | 88,904 KB |
| 実行使用メモリ | 6,272 KB |
| 最終ジャッジ日時 | 2026-03-25 06:39:34 |
| 合計ジャッジ時間 | 1,053 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 1 |
ソースコード
#include <iostream>
#include <cstdio>
#include <vector>
#include <algorithm>
#include <utility>
#include <cmath>
using namespace std;
const double EPS = 1e-12;
int main() {
int t;
double in_x, in_y, x, y;
cin >> t;
vector<double> ans(t, 0.0);
for (int i = 0; i < t; i++) {
x = -100;
for (int i = 0; i < 6; i++) {
cin >> in_x >> in_y;
if (in_y >= -EPS && in_x > x) {
x = in_x;
y = in_y;
}
}
double diff = x == 0 ? 0 : atan(y / x) * 180 / M_PI;
ans[i] = diff;
}
for (int i = 0; i < t; i++) {
printf("%.16f\n", ans[i]);
}
return 0;
}