QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#760413 | #9289. 1%-Euclidean | N_z_ | WA | 1510ms | 7340kb | C++23 | 6.7kb | 2024-11-18 16:52:11 | 2024-11-18 16:52:12 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
struct time_helper{
#ifdef LOCAL
clock_t time_last;time_helper(){time_last=clock();}void test(){auto time_now=clock();std::cerr<<"time:"<<1.*(time_now-time_last)/CLOCKS_PER_SEC<<";all_time:"<<1.*time_now/CLOCKS_PER_SEC<<std::endl;time_last=time_now;}~time_helper(){test();}
#else
void test(){}
#endif
}time_helper;
#ifdef LOCAL
#include"dbg.h"
#else
#define dbg(...) (__VA_ARGS__)
#endif
namespace Fread{const int SIZE=1<<16;char buf[SIZE],*S,*T;inline char getchar(){if(S==T){T=(S=buf)+fread(buf,1,SIZE,stdin);if(S==T)return'\n';}return *S++;}}namespace Fwrite{const int SIZE=1<<16;char buf[SIZE],*S=buf,*T=buf+SIZE;inline void flush(){fwrite(buf,1,S-buf,stdout);S=buf;}inline void putchar(char c){*S++=c;if(S==T)flush();}struct NTR{~NTR(){flush();}}ztr;}
#define getchar Fread::getchar
#define putchar Fwrite::putchar
int print_precision=10;bool print_T_endl=1;char print_between=' ';
template<typename T>struct is_char{static constexpr bool value=(std::is_same<T,char>::value||std::is_same<T,signed char>::value||std::is_same<T,unsigned char>::value);};template<typename T>struct is_integral_ex{static constexpr bool value=(std::is_integral<T>::value||std::is_same<T,__int128>::value)&&!is_char<T>::value;};template<typename T>struct is_floating_point_ex{static constexpr bool value=std::is_floating_point<T>::value||std::is_same<T,__float128>::value;};namespace Fastio{struct Reader;struct Writer;template<size_t id>struct read_tuple{template<typename...T>static void read(Reader&stream,std::tuple<T...>&x){read_tuple<id-1>::read(stream,x);stream>>get<id-1>(x);}};template<>struct read_tuple<0>{template<typename...T>static void read([[maybe_unused]]Reader&stream,[[maybe_unused]]std::tuple<T...>&x){}};template<size_t id>struct print_tuple{template<typename...T>static void print(Writer&stream,const std::tuple<T...>&x){print_tuple<id-1>::print(stream,x);putchar(print_between);stream<<get<id-1>(x);}};template<>struct print_tuple<1>{template<typename...T>static void print(Writer&stream,const std::tuple<T...>&x){stream<<get<0>(x);}};template<>struct print_tuple<0>{template<typename...T>static void print([[maybe_unused]]Writer&stream,[[maybe_unused]]const std::tuple<T...>&x){}};
struct Reader{template<typename T>typename std::enable_if_t<std::is_class<T>::value,Reader&>operator>>(T&x){for(auto &y:x)*this>>y;return *this;}template<typename...T>Reader&operator>>(std::tuple<T...>&x){read_tuple<sizeof...(T)>::read(*this,x);return *this;}template<typename T>typename std::enable_if_t<is_integral_ex<T>::value,Reader&>operator>>(T&x){char c=getchar();short f=1;while(c<'0'||c>'9'){if(c=='-')f*=-1;c=getchar();}x=0;while(c>='0'&&c<='9'){x=(x<<1)+(x<<3)+(c^48);c=getchar();}x*=f;return *this;}template<typename T>typename std::enable_if_t<is_floating_point_ex<T>::value,Reader&>operator>>(T&x){char c=getchar();short f=1,s=0;x=0;T t=0;while((c<'0'||c>'9')&&c!='.'){if(c=='-')f*=-1;c=getchar();}while(c>='0'&&c<='9'&&c!='.')x=x*10+(c^48),c=getchar();if(c=='.')c=getchar();else return x*=f,*this;while(c>='0'&&c<='9')t=t*10+(c^48),s++,c=getchar();while(s--)t/=10.0;x=(x+t)*f;return*this;}template<typename T>typename std::enable_if_t<is_char<T>::value,Reader&>operator>>(T&c){c=getchar();while(c=='\n'||c==' '||c=='\r')c=getchar();return *this;}Reader&operator>>(char*str){int len=0;char c=getchar();while(c=='\n'||c==' '||c=='\r')c=getchar();while(c!='\n'&&c!=' '&&c!='\r')str[len++]=c,c=getchar();str[len]='\0';return*this;}template<typename T1,typename T2>Reader&operator>>(std::pair<T1,T2>&x){*this>>x.first>>x.second;return *this;}Reader&operator>>(std::string&str){str.clear();char c=getchar();while(c=='\n'||c==' '||c=='\r')c=getchar();while(c!='\n'&&c!=' '&&c!='\r')str.push_back(c),c=getchar();return*this;}Reader(){}}cin;const char endl='\n';
struct Writer{typedef __int128 mxdouble;template<typename T>typename std::enable_if_t<std::is_class<T>::value,Writer&>operator<<(const T&x){for(auto q:x){*this<<q;if(!is_class<decltype(q)>::value)*this<<print_between;}if(!is_class<typename T::value_type>::value&&print_T_endl)*this<<'\n';return *this;}template<typename...T>Writer&operator<<(const std::tuple<T...>&x){print_tuple<sizeof...(T)>::print(*this,x);if(print_T_endl)*this<<'\n';return *this;}template<typename T>typename std::enable_if_t<is_integral_ex<T>::value,Writer&>operator<<(T x){if(x==0)return putchar('0'),*this;if(x<0)putchar('-'),x=-x;static int sta[45];int top=0;while(x)sta[++top]=x%10,x/=10;while(top)putchar(sta[top]+'0'),--top;return*this;}template<typename T>typename std::enable_if_t<is_floating_point_ex<T>::value,Writer&>operator<<(T x){if(x<0)putchar('-'),x=-x;x+=pow(10,-print_precision)/2;mxdouble _=x;x-=(T)_;static int sta[45];int top=0;while(_)sta[++top]=_%10,_/=10;if(!top)putchar('0');while(top)putchar(sta[top]+'0'),--top;putchar('.');for(int i=0;i<print_precision;i++)x*=10;_=x;while(_)sta[++top]=_%10,_/=10;for(int i=0;i<print_precision-top;i++)putchar('0');while(top)putchar(sta[top]+'0'),--top;return*this;}template<typename T>typename std::enable_if_t<is_char<T>::value,Writer&>operator<<(const T&c){putchar(c);return*this;}Writer&operator<<(char*str){int cur=0;while(str[cur])putchar(str[cur++]);return *this;}Writer&operator<<(const char*str){int cur=0;while(str[cur])putchar(str[cur++]);return*this;}template<typename T1,typename T2>Writer&operator<<(const std::pair<T1,T2>&x){*this<<x.first<<print_between<<x.second;if(print_T_endl)*this<<'\n';return *this;}Writer&operator<<(const std::string&str){int st=0,ed=str.size();while(st<ed)putchar(str[st++]);return*this;}Writer(){}}cout;}
#define cin Fastio::cin
#define cout Fastio::cout
#define endl Fastio::endl
template<class Fun>class y_combinator_result{Fun fun_;public:template<class T>explicit y_combinator_result(T &&fun): fun_(std::forward<T>(fun)) {}template<class ...Args>decltype(auto) operator()(Args &&...args){return fun_(std::ref(*this), std::forward<Args>(args)...);}};template<class Fun>decltype(auto) y_combinator(Fun &&fun){return y_combinator_result<std::decay_t<Fun>>(std::forward<Fun>(fun));}
void init();void solve(int tc);
main()
{
init();int t=1;
// cin>>t;
for(int tc=1;tc<=t;tc++)solve(tc);
}
void init()
{
}
constexpr int lim=1e8,nlim=1e4;
mt19937 mt(random_device{}());
void solve([[maybe_unused]]int tc)
{
int n;
cin>>n;
vector<pair<int,int>>pt(n);
cin>>pt;
int cnt=0;
double sum=0;
auto sqr=[&](int v){return 1ll*v*v;};
auto getdis=[&](int x,int y){return sqrt(sqr(pt[x].first-pt[y].first)+sqr(pt[x].second-pt[y].second));};
if(n<=nlim)
{
for(int x=0;x<n;x++)
for(int y=0;y<x;y++)
sum+=getdis(x,y),cnt++;
}
else
{
for(int t=0;t<lim;t++)
{
int x=mt()%n,y=mt()%n;
if(x==y)continue;
sum+=getdis(x,y),cnt++;
}
}
cout<<sum*n*(n-1)/2/cnt<<endl;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 1ms
memory: 3592kb
input:
3 -1 2 2 2 -1 -2
output:
12.0000000000
result:
ok error = 0.00000 (0.00000e+00)
Test #2:
score: 0
Accepted
time: 0ms
memory: 3948kb
input:
4 0 0 2 0 0 2 2 2
output:
13.6568542495
result:
ok error = 0.00000 (3.66117e-11)
Test #3:
score: 0
Accepted
time: 0ms
memory: 3796kb
input:
10 -5 -9 5 -1 -8 -7 -6 10 1 -2 -1 -6 -2 3 -3 -1 -5 2 -10 9
output:
447.9360126413
result:
ok error = 0.00000 (6.69782e-13)
Test #4:
score: 0
Accepted
time: 0ms
memory: 3848kb
input:
100 38 5 49 98 51 73 -9 88 85 -17 74 -89 -7 -83 75 -45 -7 -86 -1 -83 64 29 -100 70 94 -31 33 -58 -19 53 -68 -24 -20 -95 -58 -82 96 17 -57 -66 25 -82 33 -88 -30 9 -78 -81 -96 80 -61 98 -70 91 18 -75 -74 -57 -49 46 -30 83 33 -71 97 -36 77 -98 -41 -80 -10 -58 -65 -82 75 -56 71 -99 -79 18 -69 45 85 37 1...
output:
568237.0112857681
result:
ok error = 0.00000 (2.04871e-16)
Test #5:
score: 0
Accepted
time: 1ms
memory: 3888kb
input:
1000 944 590 -334 904 889 -282 425 -325 -103 -809 993 911 143 443 -932 605 -301 -176 -157 146 -633 -399 -150 955 -363 -14 -817 493 -47 720 -928 -965 -8 -316 272 -299 907 -72 -844 758 642 -52 235 498 -822 204 -224 618 337 55 -809 710 -564 -937 -638 -371 -961 244 -652 408 -298 955 264 -680 -963 -767 -...
output:
519539465.9520097374
result:
ok error = 0.00000 (0.00000e+00)
Test #6:
score: 0
Accepted
time: 88ms
memory: 4064kb
input:
10000 -659 -2844 -8357 -6691 -1461 -3785 -2767 2416 -8822 1703 9241 -2262 -1504 -3990 6987 -5208 2984 -9116 7244 2503 -6187 6720 -1624 -931 6738 -7167 2962 -4352 -6964 -8792 6241 -582 -6450 -1229 2177 -1269 1714 -3459 -7260 -8263 6329 5496 9797 -8972 927 -5671 -2721 3134 9392 5161 -5527 -2240 -983 7...
output:
520589035884.6277465820
result:
ok error = 0.00000 (1.17242e-16)
Test #7:
score: 0
Accepted
time: 1032ms
memory: 3792kb
input:
100000 -83701 75196 45765 -6235 36272 37275 -35366 -82843 8306 -1369 -28173 46051 -65089 -8781 75824 -54559 -55700 -93735 59743 86007 -72405 -47645 24812 35094 -4454 -21204 -35485 87381 28200 45650 904 -80565 38488 14842 10353 48050 66074 7042 61753 71952 55030 -92952 -44662 -94767 -59269 -34289 374...
output:
520954916897844.0000000000
result:
ok error = -0.00005 (-5.12153e-05)
Test #8:
score: 0
Accepted
time: 1480ms
memory: 7032kb
input:
500000 -583904 203313 -340892 -796716 910437 -246461 -246636 206026 -735478 953404 746547 -77553 -661769 967977 -312048 -680490 -776092 95714 140302 677488 -907238 962373 -225267 107163 714274 -295282 430205 384021 -737797 -503077 871316 171099 -234497 -767343 -149102 399526 912881 -921105 -831662 6...
output:
130333495763544320.0000000000
result:
ok error = -0.00005 (-4.68027e-05)
Test #9:
score: 0
Accepted
time: 1459ms
memory: 7304kb
input:
500000 3 8 -4 -10 6 7 5 -8 -4 4 2 8 -7 4 -10 -5 -9 -1 -7 9 7 10 3 5 2 -4 -10 -10 3 0 -3 7 -2 -9 8 4 -5 -6 2 -9 10 -4 9 4 3 -2 -6 8 0 8 -5 -9 -3 10 -9 -3 -7 -9 -7 8 -3 1 -1 -8 -9 7 -9 7 -5 0 -1 -1 -3 9 -2 -6 -5 1 7 -4 -4 5 7 5 -8 5 4 -2 6 8 6 6 4 -10 -7 -5 7 10 10 2 9 -4 -3 -6 1 9 -1 -10 -1 9 1 1 -10...
output:
1366899320423.0700683593
result:
ok error = -0.00005 (-4.89101e-05)
Test #10:
score: 0
Accepted
time: 1409ms
memory: 7264kb
input:
500000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
0.0000000000
result:
ok error = 0.00000 (0.00000e+00)
Test #11:
score: 0
Accepted
time: 1431ms
memory: 7244kb
input:
500000 -1000000 -1000000 -1000000 -1000000 1000000 1000000 1000000 1000000 -1000000 -1000000 -1000000 -1000000 -1000000 -1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 -1000000 -1000000 1000000 1000000 -1000000 -1000000 1000000 1000000 1000000...
output:
176760032343423008.0000000000
result:
ok error = -0.00009 (-9.43427e-05)
Test #12:
score: 0
Accepted
time: 1454ms
memory: 7332kb
input:
500000 -70213 -71203 -61054 -79198 -95941 28199 -11770 99304 18752 98225 73256 68069 -88777 46027 -67547 73738 -87962 -47566 48747 87313 32574 94545 93353 -35849 -97310 -23035 92492 38013 -59278 -80535 -27784 -96062 47366 88070 -21221 97722 79500 -60660 -82446 56590 19991 97981 -89590 44424 85179 52...
output:
15920615984414290.0000000000
result:
ok error = 0.00005 (5.40169e-05)
Test #13:
score: 0
Accepted
time: 1455ms
memory: 7260kb
input:
500000 -6858 -7277 2327 -9725 -5846 -8113 -5662 -8242 3573 -9339 -9999 90 -1601 9870 9875 -1571 7589 6511 -5146 -8573 -1281 -9917 4273 -9040 -4928 -8701 6890 -7247 -5057 -8626 9204 3908 6224 7826 -8209 5709 -7024 -7117 5797 8148 2480 9687 -8405 5416 -7298 6835 -4742 -8804 8882 -4594 -9285 3712 -4701...
output:
1596363463270939.7500000000
result:
ok error = -0.00001 (-9.63233e-06)
Test #14:
score: 0
Accepted
time: 1460ms
memory: 7320kb
input:
500000 -985 -166 840 -542 -303 -952 -514 -857 -170 985 -888 -458 999 -22 171 985 -997 73 937 347 -474 880 52 -998 482 875 -999 18 -465 -885 -998 54 987 -157 -992 -124 998 48 -826 563 -604 -796 971 238 904 -427 -820 571 935 352 189 981 487 873 -974 -226 987 -155 -72 997 418 -908 192 981 660 -750 881 ...
output:
164114136281301.7187500000
result:
ok error = 0.00042 (4.20036e-04)
Test #15:
score: 0
Accepted
time: 1456ms
memory: 7212kb
input:
500000 64 -76 39 91 -99 12 99 12 99 -8 96 27 8 -99 -83 -55 93 -35 -36 -93 -7 99 -19 98 49 86 99 -9 99 4 -99 -9 54 -84 68 -72 83 55 -95 30 97 -23 -10 99 99 8 -96 -27 -99 -6 29 -95 15 -98 -87 -49 68 -73 -88 -46 99 -4 -88 -46 40 91 -60 -79 47 -88 -47 88 93 -36 -91 -40 98 19 -31 94 -78 62 27 -96 -80 -59...
output:
20953502531392.7617187500
result:
ok error = 0.00700 (6.99821e-03)
Test #16:
score: 0
Accepted
time: 1472ms
memory: 7208kb
input:
500000 9 -4 8 -5 -9 1 3 -9 3 9 -2 9 -9 3 7 -7 -7 6 5 -8 -9 0 0 -9 0 -9 6 -7 0 9 1 -9 0 -9 9 -3 -1 9 -9 1 0 -9 -9 0 -9 -2 8 5 -5 -8 -9 1 8 -5 -9 -3 -8 4 2 -9 -9 2 -8 -4 2 9 -8 5 -1 -9 -3 -9 4 -9 8 5 -4 8 8 5 4 8 2 -9 -3 9 -3 9 -6 7 0 9 9 -3 9 -3 -8 -5 3 9 -9 0 -1 -9 -7 6 1 9 -7 6 4 8 -6 7 1 9 9 2 -9 ...
output:
6410338322533.6152343750
result:
ok error = -0.00965 (-9.65198e-03)
Test #17:
score: 0
Accepted
time: 1460ms
memory: 7264kb
input:
500000 77493 63204 78981 61335 80629 -59151 -63468 77277 56293 82649 -93854 -34515 95789 28712 -94567 32510 -18302 -98310 -991 99995 -98648 16384 -59389 80454 -89278 45047 -98974 -14285 -36733 93008 -13224 -99121 -95959 28137 91899 -39425 70750 -70670 -99710 -7601 -21450 97672 -50140 86521 57408 -81...
output:
16353212661260128.0000000000
result:
ok error = 0.00004 (3.51774e-05)
Test #18:
score: 0
Accepted
time: 1447ms
memory: 7316kb
input:
500000 -7563 -6541 -9999 81 8869 -4618 5594 -8288 8290 5592 9911 -1328 4562 -8898 -9949 -1007 -3501 -9366 9296 -3685 7661 6426 -4194 -9077 9635 -2674 -9980 -622 -3332 9428 8874 -4608 -8059 -5920 -7818 6234 -9041 4271 9581 2861 9808 1946 9725 2327 4861 8738 1171 9931 783 9969 9891 -1470 7658 6430 -94...
output:
2084866491635362.5000000000
result:
ok error = 0.00006 (6.38274e-05)
Test #19:
score: 0
Accepted
time: 1456ms
memory: 7200kb
input:
500000 974 223 912 -408 -693 -720 -748 -663 -932 360 368 929 -366 -930 -691 -722 -260 965 -136 990 -811 584 -86 996 -793 608 -748 663 898 -438 -319 -947 -87 -996 -762 646 146 989 95 -995 997 -72 -942 -335 681 732 843 536 345 938 566 823 -780 625 151 988 190 981 -397 -917 629 776 -934 356 -999 -17 -9...
output:
658136445119840.3750000000
result:
ok error = 0.00013 (1.28082e-04)
Test #20:
score: 0
Accepted
time: 1465ms
memory: 7208kb
input:
500000 -98 -15 3 99 88 -45 -99 3 -39 -91 77 -62 -75 65 -96 26 64 -76 -99 0 28 95 -21 -97 -74 66 98 -19 -67 -73 -49 86 -5 -99 -90 -42 -33 -94 -56 82 57 -81 -43 -90 75 -65 -73 -67 99 11 -68 -72 -81 57 -53 84 48 -87 -68 72 91 40 23 97 -94 -32 -75 -65 61 -78 -8 99 -47 88 -29 -95 31 -94 61 -78 49 86 23 9...
output:
517108827342721.2500000000
result:
ok error = 0.00335 (3.35246e-03)
Test #21:
score: 0
Accepted
time: 1454ms
memory: 7252kb
input:
500000 -6 -7 7 -7 1 -9 -1 -9 3 9 -9 0 -4 -8 -9 -1 4 9 3 9 9 3 -9 1 -8 5 -4 8 3 -9 -4 9 -4 8 9 -2 9 3 0 9 2 9 0 9 9 -4 9 1 5 -8 0 -9 -2 9 1 -9 3 -9 8 5 6 -7 -9 -1 -9 -1 -9 -3 4 8 -4 -8 6 7 2 9 3 -9 0 -9 9 2 4 -9 -9 -4 -8 -5 -6 7 -1 -9 -7 6 -8 -5 7 6 -6 -7 -5 -8 9 -1 0 9 9 0 -6 7 3 -9 -1 -9 1 -9 -8 -5...
output:
501387949669069.7500000000
result:
ok error = 0.00057 (5.69481e-04)
Test #22:
score: 0
Accepted
time: 1450ms
memory: 7264kb
input:
500000 4091 99916 -82848 -56000 -83139 55567 78550 996910 785656 -618662 37191 -92826 -81244 58304 -33057 94377 349820 -936816 2736 99962 -50179 -86498 99617 -8742 6945 -99758 -96133 -27537 23358 -97233 -15596 98776 675275 737565 -63736 77056 -49018 87161 -996339 85481 -59440 80416 72081 69313 -9757...
output:
56652587745487296.0000000000
result:
ok error = 0.00001 (9.66801e-06)
Test #23:
score: 0
Accepted
time: 1490ms
memory: 6928kb
input:
500000 -9734 2290 -762 -9970 -443 -9990 -925276 379293 -9969 782 -9967 811 929030 370002 8874 -4609 9902 1392 -9338 3577 9999 0 9858 -1673 -9998 159 153508 988147 3617 -9322 -8077 -5894 5430 -8397 -999686 25032 2420 -9702 -9722 -2340 885517 -464605 -66353 997796 -8809 4731 -3338 9426 9804 -1968 -862...
output:
47384993387736576.0000000000
result:
ok error = -0.00001 (-1.39086e-05)
Test #24:
score: 0
Accepted
time: 1455ms
memory: 7208kb
input:
500000 -567649 -823270 -944 329 -838 544 482 875 840 541 600 799 -999 7 320 947 314 949 588130 -808765 605 795 -91281 -995825 -400 -916 -503 864 543 -839 956 291 -30 999 918 -396 -470601 -882345 999 -11 499577 866269 787 -615 -999 -8 -608 -793 747 664 -401 -915 -226 -974 -621 783 -992 -122 998 -59 -...
output:
46469850468448160.0000000000
result:
ok error = 0.00004 (4.14281e-05)
Test #25:
score: 0
Accepted
time: 1459ms
memory: 7332kb
input:
500000 91 39 -719553 694437 93 -36 -67 -74 -51 -85 98 -14 74 67 -86 49 0 99 83 -54 -5 -99 -58 81 -30 -95 -92 -37 -97 21 -5 99 40 91 27 96 -49 87 -752933 658096 90 43 -85 51 -94 33 -53 -84 -16 -98 54 -83 16 -98 72 -68 -969940 -243343 294519 955645 99 8 -869531 -493876 -99 8 56 -82 -11 99 66 75 889165...
output:
46377197795489280.0000000000
result:
ok error = 0.00002 (2.02975e-05)
Test #26:
score: 0
Accepted
time: 1455ms
memory: 7260kb
input:
500000 -950662 -310226 -9 1 0 -9 9 0 1 -9 -5 8 -3 -9 -103163 994664 9 0 1 9 796592 604516 -9 -3 -8 4 -9 1 -6 7 8 -4 4 -8 -9 3 -5 8 -996917 -78460 -9 -1 -3 9 -6 7 7 6 8 4 823632 -567123 531543 -847030 788574 614939 2 -9 -329768 -944061 9 -2 -134388 -990928 -9 -3 -9 0 2 -9 4 -9 655915 -754834 -4 8 5 -...
output:
46363758206057456.0000000000
result:
ok error = -0.00007 (-7.16834e-05)
Test #27:
score: 0
Accepted
time: 1457ms
memory: 7320kb
input:
500000 -12529 2 -910470 4 672773 4 -427096 -3 763846 5 -998768 -5 964819 0 96854 3 -218123 6 24533 9 376929 4 659757 5 75593 -2 283672 -4 968735 0 722998 -7 316082 -4 -370444 9 -722614 5 773227 3 593201 0 -98193 9 418077 8 -345716 -6 -840506 -6 -23962 -7 371344 -9 -681886 -1 -351094 -7 315383 9 -725...
output:
83343835034261616.0000000000
result:
ok error = 0.00003 (2.91930e-05)
Test #28:
score: 0
Accepted
time: 1510ms
memory: 7044kb
input:
500000 -177677 -63971 -264184 -95119 716938 258107 285794 102893 -508316 -182997 889422 320221 -170689 -61456 -110221 -39691 589177 212107 -481764 -173448 -848585 -305509 833359 300034 632131 227583 401326 144488 336801 121254 326004 117367 311718 112235 -581858 -209481 -241152 -86817 115620 41624 -...
output:
83352361307252352.0000000000
result:
ok error = 0.00005 (5.26878e-05)
Test #29:
score: 0
Accepted
time: 1443ms
memory: 7304kb
input:
500000 -118165 -97756 -259636 -214805 739345 611629 -610779 -505280 305743 252946 -610688 -505210 191511 158420 -732213 -605744 -620906 -513645 -599911 -496278 -652202 -539555 -758838 -627766 -120143 -99388 -71723 -59338 481398 398244 684156 565996 -388342 -321282 417995 345792 -665258 -550335 -7262...
output:
83395872952996416.0000000000
result:
ok error = -0.00001 (-5.92403e-06)
Test #30:
score: 0
Accepted
time: 1453ms
memory: 7208kb
input:
500000 164893 278802 -506267 -856037 -197737 -334337 -409232 -691965 60219 101842 -101662 -171910 242374 409821 2549 4300 -487201 -823831 105548 178470 -230847 -390329 -333044 -563157 -39723 -67182 -216956 -366857 372695 630193 -17335 -29298 -338432 -572261 -43098 -72878 308716 522001 -78382 -132529...
output:
83318446821502688.0000000000
result:
ok error = -0.00003 (-3.14331e-05)
Test #31:
score: 0
Accepted
time: 1461ms
memory: 7324kb
input:
500000 27259 142866 28328 148474 7370 38633 148036 775994 -53454 -280270 14869 77983 -144852 -759358 -166685 -873800 -110035 -576812 7217 37813 105124 551077 -48918 -256486 45978 241064 174622 915369 -68148 -357265 -173544 -909773 -142185 -745361 133141 697945 164359 861617 -45756 -239872 -94443 -49...
output:
83383092500062992.0000000000
result:
ok error = 0.00006 (5.90700e-05)
Test #32:
score: 0
Accepted
time: 1446ms
memory: 7264kb
input:
500000 -124463 785846 86735 -547632 -68197 430602 -8330 52626 -48937 308920 -54098 341552 142660 -900763 -152037 959926 4866 -30662 156041 -985168 26291 -166042 123705 -781076 -106322 671336 17450 -110201 57585 -363577 -111736 705515 -125250 790801 136845 -864056 107458 -678507 66667 -420875 -5798 3...
output:
83301227420544880.0000000000
result:
ok error = 0.00015 (1.50020e-04)
Test #33:
score: 0
Accepted
time: 1460ms
memory: 7336kb
input:
500000 28816 -52406 437329 -795500 3366 -6141 226258 -411567 -428329 779134 -165063 300229 -350413 637399 -376102 684136 146777 -266978 103 -211 -207356 377184 39064 -71044 -372888 678292 87430 -159041 -181574 330300 -310496 564793 171333 -311674 95233 -173249 258384 -469985 -28421 51686 476153 -866...
output:
83269202135089264.0000000000
result:
ok error = 0.00004 (3.82468e-05)
Test #34:
score: 0
Accepted
time: 1466ms
memory: 7292kb
input:
500000 429954 -379051 109594 -96614 -700632 617697 504256 -444555 -499749 440587 -161196 142123 -230497 203221 -116766 102943 -519601 458099 -166932 147178 -507461 447383 495760 -437071 105747 -93228 -439948 387868 -51507 45411 -555989 490182 -454119 400356 415132 -366002 -633235 558269 622559 -5488...
output:
83356225400046800.0000000000
result:
ok error = 0.00004 (3.74296e-05)
Test #35:
score: 0
Accepted
time: 1464ms
memory: 7284kb
input:
500000 88808 -35160 -842746 333680 169741 -67200 286541 -113451 -389605 154263 -92920 36794 282363 -111799 833545 -330024 -323357 128033 49863 -19746 -171455 67881 -709576 280946 233407 -92404 185991 -73633 738286 -292309 55792 -22087 60127 -23813 -791012 313194 -694593 275013 596395 -236139 -576919...
output:
83369384643094096.0000000000
result:
ok error = -0.00010 (-1.04274e-04)
Test #36:
score: 0
Accepted
time: 1462ms
memory: 7188kb
input:
500000 785754 -24689 439289 -13810 136787 -4300 515422 -16207 181172 -5691 -835374 26253 733424 -23039 -376363 11825 -639239 20083 652225 -20502 964231 -30294 -434966 13664 -749812 23555 916991 -28809 292890 -9198 -21497 668 -498080 15656 -459276 14423 777214 -24420 878762 -27620 -426161 13387 60078...
output:
83380850162077312.0000000000
result:
ok error = 0.00006 (5.74879e-05)
Test #37:
score: 0
Accepted
time: 1450ms
memory: 7320kb
input:
500000 744713 241979 731166 237573 -651509 -211679 -65153 -21163 810658 263395 -427583 -138932 268650 87285 572692 186069 546895 177688 62035 20162 224048 72798 670434 217846 357208 116056 -234904 -76327 621258 201858 657182 213524 -548902 -178359 -202299 -65723 482954 156924 -759608 -246805 -595872...
output:
83329888341012144.0000000000
result:
ok error = 0.00004 (3.51526e-05)
Test #38:
score: 0
Accepted
time: 1456ms
memory: 7272kb
input:
500000 255961 198534 -671014 -520485 506909 393203 -27345 -21205 -67994 -52726 45629 35400 -283459 -219870 -739662 -573754 -263925 -204719 244251 189453 -215244 -166976 85681 66460 -278951 -216383 -462300 -358600 634728 492350 -131871 -102287 538003 417301 327233 253816 -581065 -450716 -516269 -4004...
output:
83259448663079552.0000000000
result:
ok error = 0.00000 (2.65439e-06)
Test #39:
score: 0
Accepted
time: 1464ms
memory: 7236kb
input:
500000 470058 740700 62885 99081 329012 518435 -226584 -357034 -236297 -372346 445591 181329 -2834 -4446 -120855 -190426 298691 470673 -325706 -513223 354071 557918 -483820 -762394 211327 332984 -288261 -454233 424559 668999 -330736 -521150 -465015 -732730 -141031 -222220 -81415 -128294 289495 45618...
output:
83295805357338496.0000000000
result:
ok error = 0.00007 (7.39766e-05)
Test #40:
score: 0
Accepted
time: 1443ms
memory: 7244kb
input:
500000 88548 396176 -152623 -682773 108486 485365 -12574 -56244 -186491 -834329 52903 236645 -175118 -783465 82654 369801 -112874 -504976 142257 636472 -114516 -512329 122273 547005 -110385 -493873 -152559 -682514 36611 163805 62618 280154 208237 931608 -12583 -56286 132973 594940 200335 896221 6613...
output:
83352463651030240.0000000000
result:
ok error = 0.00003 (2.79500e-05)
Test #41:
score: 0
Accepted
time: 1448ms
memory: 7340kb
input:
500000 -92178 729690 99448 -787259 21971 -173862 -109571 867334 93250 -738117 -118421 937334 -85559 677272 -57555 455598 84937 -672333 50400 -398887 -97490 771701 64628 -511549 92294 -730513 -71821 568580 -98930 783032 -27709 219285 44029 -348559 34945 -276594 -73872 584780 53908 -426683 -62762 4968...
output:
83471953869058384.0000000000
result:
ok error = 0.00004 (3.85852e-05)
Test #42:
score: 0
Accepted
time: 1446ms
memory: 7264kb
input:
500000 377363 -740625 419757 -823810 -354392 695530 378837 -743482 170599 -334821 -423557 831270 381449 -748630 348406 -683772 363019 -712449 -326446 640688 441055 -865618 -235416 462050 260454 -511181 97967 -192267 -109611 215136 26449 -51925 -437181 858016 -153492 301251 111554 -218917 -140284 275...
output:
83443903057600400.0000000000
result:
ok error = 0.00002 (1.70328e-05)
Test #43:
score: 0
Accepted
time: 1458ms
memory: 7272kb
input:
500000 -35169 33022 83496 -78399 533344 -500851 437949 -411250 -150052 140900 -245529 230570 79962 -75085 -273678 256998 704979 -662019 -94623 88852 -31109 29195 -304508 285967 -503182 472517 57240 -53751 724014 -679885 -570343 535596 -149939 140792 -514041 482720 485425 -455831 -217841 204573 36024...
output:
83459909973352208.0000000000
result:
ok error = 0.00007 (6.96549e-05)
Test #44:
score: 0
Accepted
time: 1465ms
memory: 7272kb
input:
500000 611899 -264793 159583 -69060 868547 -375858 -807625 349500 201809 -87326 548510 -237364 659936 -285583 886406 -383590 270655 -117126 -617745 267322 -86476 37426 -722860 312815 637188 -275730 222839 -96439 723287 -312989 829039 -358757 422464 -182808 402279 -174079 -19972 8646 -349473 151226 5...
output:
83281942749028464.0000000000
result:
ok error = 0.00002 (1.82109e-05)
Test #45:
score: 0
Accepted
time: 1449ms
memory: 7280kb
input:
500000 -152211 9570 -763003 48005 38503 -2431 551203 -34688 780391 -49088 -492826 31005 574876 -36173 874080 -54988 819498 -51553 573639 -36097 -824961 51901 976424 -61431 394997 -24857 -121540 7655 -874110 54988 -932392 58664 -421000 26478 296901 -18686 -16353 1032 192719 -12126 250757 -15776 -2275...
output:
83309045414623568.0000000000
result:
ok error = -0.00001 (-1.24752e-05)
Test #46:
score: 0
Accepted
time: 1457ms
memory: 7268kb
input:
500000 -179635 -52196 -839491 -243894 99069 28779 -338213 -98261 216632 62937 -49407 -14360 -97598 -28354 145490 42260 912190 265010 -482654 -140214 146317 42507 -491975 -142933 -563485 -163705 160302 46562 907709 263720 -591917 -171975 -799352 -232227 -541031 -157187 -204334 -59372 921484 267719 91...
output:
83297135550263888.0000000000
result:
ok error = -0.00005 (-5.15186e-05)
Extra Test:
score: -3
Extra Test Failed : Wrong Answer on 3
time: 1437ms
memory: 7300kb
input:
500000 -1000000 -1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 1000000 100...
output:
1679378689287.1455078125
result:
wrong answer error = 0.18755 (1.87546e-01)