結果
問題 | No.105 arcの六角ボルト |
ユーザー | LayCurse |
提出日時 | 2014-11-27 14:06:32 |
言語 | C++11 (gcc 11.4.0) |
結果 |
AC
|
実行時間 | 27 ms / 5,000 ms |
コード長 | 475 bytes |
コンパイル時間 | 1,296 ms |
コンパイル使用メモリ | 143,320 KB |
実行使用メモリ | 4,376 KB |
最終ジャッジ日時 | 2023-09-01 22:18:56 |
合計ジャッジ時間 | 1,899 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge14 |
ソースコード
#include<bits/stdc++.h> using namespace std; #define REP(i,a,b) for(i=a;i<b;i++) #define rep(i,n) REP(i,0,n) int main(){ int i, j, k; int T; double X, Y, th, pi = acos(0)*2; double res; scanf("%d",&T); while(T--){ res = 1e10; rep(i,6){ scanf("%lf%lf",&X,&Y); th = atan2(Y,X); if(th < -1e-9) continue; res = min(res, th); } res = res * 180 / pi; printf("%.16f\n",res); } return 0; }