#include using namespace std; #define rep(i,n) for(int i=0; i<(int)n; i++) #define repi(i,m,n) for(int i=(int)m; i<=(int)n; i++) #define rrep(i,n) for(int i=(int)n-1; i>=0; i--) #define rrepi(i,m,n) for(int i=(int)n; i>=(int)m; i--) #define all(x) x.begin(),x.end() template inline bool chmin(T& a, const T& b) { return a > b ? a = b, true : false; }; template inline bool chmax(T& a, const T& b) { return a < b ? a = b, true : false; }; template void uniq(std::vector &v){ std::sort(v.begin(),v.end()); v.erase(unique(v.begin(),v.end()),v.end()); } using ll = long long; int main(){ int n; cin >> n; double sx = 0,sy = 0,tx = 0,ty = 0,x,y; rep(i,n){ cin >> x >> y; sx += x; sy += y; } rep(i,n){ cin >> x >> y; tx += x; ty += y; } cout << fixed << setprecision(15) << hypot(tx,ty)/hypot(sx,sy) << endl; return 0; }