結果
問題 |
No.3042 拡大コピー
|
ユーザー |
|
提出日時 | 2025-02-28 21:57:11 |
言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 621 bytes |
コンパイル時間 | 3,065 ms |
コンパイル使用メモリ | 278,244 KB |
実行使用メモリ | 8,236 KB |
最終ジャッジ日時 | 2025-03-01 07:38:23 |
合計ジャッジ時間 | 5,076 ms |
ジャッジサーバーID (参考情報) |
judge6 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | WA * 24 |
ソースコード
#include<bits/stdc++.h> using namespace std; #pragma GCC optimize("O3") #pragma GCC optimize("unroll-loops") using ll=long long; using ld=long double; int main(){ cin.tie(nullptr); ios_base::sync_with_stdio(false); int N;cin>>N; pair<ld,ld> P={2e9,2e9},Q=P; for(int i=0;i<N;i++){ pair<ld,ld> p;cin>>p.first>>p.second; if(p.first==0&&p.second==0)continue; P=min(P,p); } for(int i=0;i<N;i++){ pair<ld,ld> q;cin>>q.first>>q.second; if(q.first==0&&q.second==0)continue; Q=min(Q,q); } swap(P,Q); ld ans=hypotl(P.first,P.second)/hypotl(Q.first,Q.second); cout<<fixed<<setprecision(20)<<ans<<endl; }