QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#53535#2173. What's Our Vector, Victor?not_so_organicAC ✓124ms5044kbC++112.7kb2022-10-05 13:13:012022-10-05 13:13:03

Judging History

This is the latest submission verdict.

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2022-10-05 13:13:03]
  • Judged
  • Verdict: AC
  • Time: 124ms
  • Memory: 5044kb
  • [2022-10-05 13:13:01]
  • Submitted

answer

#include <cstdio>
#include <cctype>
#include <vector>
#include <cmath>

#define sqr(x) (x*x)

#define maxn 555

template<class T>

inline T read() {
    T r = 0, f = 0;
    char c;

    while (!isdigit(c = getchar()))
        f |= (c == '-');

    while (isdigit(c))
        r = (r << 1) + (r << 3) + (c & 15), c = getchar();

    return f ? -r : r;
}

template<class T>

inline T abs(T a) {
    return a < 0 ? -a : a;
}

constexpr double eps = 1e-9;

#define vec std::vector<double>

template<class T1, class T2>

inline void Gauss(int n, int m, T1 &a, T2 &b) {
    for (int i = 1; i <= n; i++) {
        if (abs(a[i][i] - 1) > eps) {
            for (int j = i + 1; j <= m; j++)
                a[i][j] /= a[i][i];

            b[i] /= a[i][i], a[i][i] = 1.0000000;
        }

        for (int j = 1; j <= n; j++) {
            if (i == j)
                continue;

            double d = a[j][i];

            for (int k = i; k <= m; k++)
                a[j][k] -= a[i][k] * d;

            b[j] -= b[i] * d;
        }
    }
}

int D, n, r;

double R, v[maxn], b[maxn], c[maxn];

double A[maxn][maxn], B[maxn][maxn];

inline void out() {
    for (int i = 1; i <= D; i++)
        printf("%.6lf ", v[i] - b[i]);
}

int main() {
    D = read<int>(), n = read<int>() - 1;

    for (int i = 1; i <= D; i++)
        scanf("%lf", &v[i]);

    scanf("%lf", &R);

    if (!n) {
        b[1] = R;
        return out(), 0;
    }

    int lim = n > D ? D : n;

    for (int i = 1; i <= lim; i++) {
        for (int j = 1; j <= D; j++) {
            scanf("%lf", &A[i][j]);
            A[i][j] -= v[j], b[i] -= sqr(A[i][j]);
        }

        double Rr;
        scanf("%lf", &Rr);
        (b[i] += sqr(Rr) - sqr(R)) /= 2;
    }

    if (n >= D) {
        Gauss(D, D, A, b);
        return out(), 0;
    }

    Gauss(n, D, A, b), r = D - n;

    for (int i = n + 1; i <= D; i++)
        A[i][i] = -1;

    for (int i = 1; i <= r; i++) {
        for (int j = 1; j <= r; j++) {
            int lim = (i > j ? i : j) + n;

            for (int k = 1; k <= lim; k++)
                B[i][j] += A[k][i + n] * A[k][j + n];
        }

        for (int k = 1; k <= i + n; k++)
            c[i] -= A[k][i + n] * b[k];
    }

    Gauss(r, r, B, c);

    for (int i = 1; i <= r; i++)
        for (int j = 1; j <= D; j++)
            b[j] += c[i] * A[j][i + n];

    double dis = R * R, Dis = 0;

    for (int i = 1; i <= D; i++) {
        dis -= b[i] * b[i];
        Dis += A[i][n + 1] * A[i][n + 1];
    }

    dis = sqrt(dis / Dis);

    for (int i = 1; i <= n + 1; i++)
        b[i] += A[i][n + 1] * dis;

    out();
    return 0;
}

详细

Test #1:

score: 100
Accepted
time: 122ms
memory: 3948kb

input:

500 500
60.00268893933372283 70.35885554610950976 -8.98574176457012186 46.16014112676185732 66.31422279348288384 29.03050764912902082 -35.06996828144599476 -59.10319321730690234 67.85808505028276727 20.30232033048615392 62.38784996896146140 59.92659390534240060 -36.26787439344059294 30.8251981981496...

output:

19.213142 6.611601 21.420048 56.938648 -89.716047 92.932289 70.957692 11.495543 -48.368594 38.693811 50.077429 7.628612 2.214806 -37.313991 -95.506121 -67.783477 -6.434226 45.246943 -27.515746 19.963864 30.175528 12.037772 2.578049 -3.382009 -42.445399 -34.156342 -99.671959 -25.598700 -18.341325 50....

result:

ok accepted

Test #2:

score: 0
Accepted
time: 124ms
memory: 3948kb

input:

500 500
-20.46791708061053328 -78.90373004342441732 -47.09421721341704625 49.96697218958462372 48.99528416466444014 -46.87780686216100889 73.68284736943891744 -53.69249802982882613 -92.37158007019175443 -97.95346943385396798 -47.79109018973426259 82.31965483504592385 -72.09718577745493917 -32.376534...

output:

-1.521535 4.569394 -55.153740 -30.820612 -4.530071 -40.748049 -98.081747 -70.679434 33.758001 40.830787 -79.970102 28.761106 74.116938 99.200661 63.146662 13.487239 87.815281 -79.248517 -94.837177 -18.868256 -7.222066 -62.708884 -80.089420 4.857491 40.655309 -82.908005 -88.063427 95.415769 36.411617...

result:

ok accepted

Test #3:

score: 0
Accepted
time: 102ms
memory: 3944kb

input:

500 500
91.75754360584323877 -74.07465057030329092 -30.06919963013949371 -22.45376960826932589 -94.33818252302211249 95.43185666705545600 -35.93139380204742395 -46.28091101025437837 20.25588702053946122 -31.98355965847254367 96.27926708531694544 17.21195108047088240 -16.00480323252260462 -14.1553994...

output:

26.967974 -85.519689 33.005153 56.449177 96.202419 2.144965 46.159301 -10.552477 95.187809 89.036703 53.309914 47.810936 -44.114936 -38.681178 20.300046 -79.559567 -83.218728 81.040642 63.609693 -32.594960 -3.142877 68.742505 -41.808963 31.675038 34.858279 -48.429391 -88.783492 -8.346761 -45.549240 ...

result:

ok accepted

Test #4:

score: 0
Accepted
time: 109ms
memory: 3940kb

input:

500 500
53.59239375857157484 1.29576452891167548 -55.60357761919549802 2.89491049833583247 -72.25117082444128869 -44.92736039007480997 6.81675337705620166 -46.20517542139523925 20.56179110027964896 99.93596620202598046 -30.87710828002636276 60.42621397022924157 79.91458345844398536 94.56182305252031...

output:

25.331926 6.051320 41.151461 -77.215689 76.991832 80.569049 93.068701 -33.387834 -33.193271 -89.276318 60.993561 21.823631 -91.880447 76.375585 26.484593 -41.677366 16.220865 81.946627 29.069514 -11.928903 65.546532 -3.075796 22.729355 59.322712 18.434060 79.136599 -69.547984 32.225471 92.009619 -41...

result:

ok accepted

Test #5:

score: 0
Accepted
time: 94ms
memory: 3864kb

input:

500 500
-63.61543927507285190 43.87221058298641196 8.16924114047013461 -34.92232278546450175 91.80142804719758942 -76.82013016900501157 25.06001121373941487 48.24958448628115093 65.82846176112221315 33.19899446519090702 84.05389321600614494 -78.49637158041961982 87.99406312213668002 -60.859516869891...

output:

8.134857 -23.757280 -99.866784 78.596821 4.686765 -52.354958 -60.652581 45.108683 75.545161 -86.722210 46.029248 -47.954222 -96.315571 1.058144 63.371793 96.969246 99.731048 87.265359 4.438199 4.153335 77.959912 -84.932434 -31.316507 28.628955 37.732379 -1.335632 -49.792763 13.584584 -52.040695 -56....

result:

ok accepted

Test #6:

score: 0
Accepted
time: 1ms
memory: 1976kb

input:

24 114
19.60728784212125220 62.05571106800468328 -77.66722345143722350 83.32150488873739391 85.61849285200199233 -61.26186974500755866 54.01645372221616981 -19.69713224000579999 -10.16958551834513003 -18.69109461054532062 9.59051520125903778 91.21514401069063638 89.60632230190051928 -51.201061482129...

output:

8.327924 27.932654 97.448548 38.207239 85.804989 55.070135 -74.250153 86.457297 -48.880037 -27.280581 97.358297 4.232461 37.098004 -34.464352 -1.523639 -92.855376 -54.070803 -60.133603 -22.704205 45.517584 65.460633 66.091305 97.782307 -58.664804 

result:

ok accepted

Test #7:

score: 0
Accepted
time: 0ms
memory: 1896kb

input:

46 97
43.01678189681189224 87.56570778950447220 9.14039085211038582 26.33206129795307504 -24.34885933455943530 0.05861471454515765 -70.42820734313679054 59.02215026766580763 -79.72741868434044932 35.60017247547804686 25.77535585268205409 92.78420121683043931 50.59296099595243845 -61.7776387073462913...

output:

64.517294 -56.630659 59.529028 55.245520 -29.447260 87.758960 96.897819 75.662891 -36.870826 -61.233033 0.552811 -9.889132 29.953122 -41.158646 -49.737787 -30.590514 -66.743075 -7.513753 84.515676 55.348988 -92.895952 -84.333955 -7.936380 -95.554897 -88.310484 -30.219802 -12.224962 95.564449 85.2854...

result:

ok accepted

Test #8:

score: 0
Accepted
time: 1ms
memory: 1820kb

input:

15 284
21.00862660821213979 21.01836955459566525 -92.59898566394279840 72.83891547702586422 37.19660542291052252 58.75752575321905624 -58.77746253675046972 -75.78702662529354939 -51.08831966203057817 37.59103345051687484 78.06776201507187807 -47.64951581683278903 86.22301376779532234 87.983435491574...

output:

33.509675 75.442494 25.672060 -29.474750 86.909873 -24.142676 -91.911409 -79.698153 60.522349 -92.832407 -0.599784 17.592794 31.743537 35.913695 53.435798 

result:

ok accepted

Test #9:

score: 0
Accepted
time: 1ms
memory: 2028kb

input:

19 424
-16.81700811299913312 -99.00108212106096062 -91.34139981256581109 60.88738598253169698 96.60168904677493629 25.16047301803423863 39.17587188905130802 -88.89020758325538907 16.66405739466397051 14.19779632163533734 -12.13768283737013576 94.71465700089734696 -4.46422341014425683 99.590922359294...

output:

-4.635003 -62.570890 -96.332119 95.044782 -54.665628 83.476583 -88.330762 34.736204 -64.051056 -25.607523 46.197265 2.372630 -10.059198 -13.782827 22.203613 59.367909 97.251818 -57.762745 -81.963641 

result:

ok accepted

Test #10:

score: 0
Accepted
time: 2ms
memory: 1908kb

input:

39 240
-17.49573620249577743 -14.20168813856275847 3.40454276185926119 75.25294275126461230 3.64382503532986846 -66.13690704428722711 9.54219281803891306 4.33429550843416678 -93.68468592834675235 -17.02270905586702554 18.67022731122480650 63.43606748481644786 14.80457613629361902 -82.867111145937784...

output:

-88.197448 -18.160433 61.746127 -72.313775 -79.029839 92.291434 42.057515 11.756414 82.458544 -5.800327 -82.159552 70.777912 3.160694 -87.670017 77.549916 -33.806110 -31.922199 -7.741266 -6.062712 -25.270814 -0.867182 23.479581 48.643234 -62.690854 -64.366493 25.811552 -98.888466 64.260982 -77.25932...

result:

ok accepted

Test #11:

score: 0
Accepted
time: 3ms
memory: 2328kb

input:

94 37
-97.74217056704389961 -34.72707124177070170 -5.18996578341727854 89.27537859475728510 -15.17925192708750615 -58.80623411956585045 6.67768502706442746 9.27371520989450460 -0.76898730002019988 -12.16379417034083588 -97.04781848445374237 -4.61915628555445323 67.16463977789777573 -98.0799613713748...

output:

-15.973362 100.452312 41.956751 79.150395 12.298046 -9.387149 83.368020 132.693956 -22.147972 -137.307201 49.233598 -100.426157 3.684880 -39.993389 68.388498 -79.326165 -47.826302 -49.581759 78.898585 -27.021439 2.335798 -159.224650 26.501428 -58.639153 -30.662620 -100.074884 1.770889 42.050219 28.6...

result:

ok accepted

Test #12:

score: 0
Accepted
time: 2ms
memory: 2228kb

input:

81 31
51.81180666086186193 4.42519101702015405 -99.52683614255568045 -78.73219118895721635 79.13631206663259832 -62.14210001674649675 77.01555907099057663 96.10429867603977527 -71.63979952372569926 31.92804200050832719 2.39923469427824898 -15.81312766092013078 -3.78675758288882491 -96.89700984284483...

output:

62.097109 -25.943237 148.230470 -166.148436 -77.353643 -30.573110 22.453938 -73.368196 136.896793 -45.992399 -56.463864 64.530733 74.848969 -29.189295 -49.547394 -129.422756 -15.572474 38.237202 44.139989 -25.302089 65.495431 -68.173111 170.678820 -32.371733 26.191867 -86.243340 2.679768 -99.683834 ...

result:

ok accepted

Test #13:

score: 0
Accepted
time: 37ms
memory: 4720kb

input:

368 15
22.30119005935810605 43.42786705247092982 -32.28926734891730632 -57.98761219344181939 -45.31478884634214666 53.04804763990063066 46.08811206966319673 -45.60493877541469487 -14.51504417311522843 85.52370945799654578 92.80145323913885136 94.08183990667501462 96.53825049915519685 -51.75960693925...

output:

49.123372 -0.228922 -80.932952 406.224069 -4.204344 -376.582466 54.372550 -51.030577 533.283739 476.211486 -116.680081 285.145597 216.336886 394.502734 258.166078 -5.155449 -43.707220 -22.434103 8.820945 20.640469 -2.057833 -28.094215 0.671693 17.239296 -1.484565 -42.649063 -16.699400 -0.684311 -1.5...

result:

ok accepted

Test #14:

score: 0
Accepted
time: 58ms
memory: 5044kb

input:

417 40
44.68655184642963718 -99.57530073803870607 -14.93036383109003395 23.41593487735389090 29.30749689971099770 -12.17392273069064856 79.34058425615467058 -35.84876537980680666 72.50759393990819035 83.68078753407559134 -5.69786294576199737 -6.93653269724951826 87.39999249217245847 64.6174490928109...

output:

-479.740817 -223.345247 8.119211 74.544339 -158.195191 454.271765 0.336290 1.599499 170.237646 -178.398592 78.030172 -140.289683 235.539947 -22.838247 -106.433002 -29.395142 274.683283 -141.776488 -58.734283 23.810230 -13.909174 118.665838 167.131683 -426.679847 3.403121 -19.162698 -73.145805 81.024...

result:

ok accepted

Test #15:

score: 0
Accepted
time: 4ms
memory: 2540kb

input:

117 39
93.39662242328662956 49.47614796316665320 88.12818584496389462 -41.60092472064344804 -93.31577807190411988 40.70668323938937760 97.74228125485441865 16.47170421620938896 19.20357999198667187 6.73479762799897230 51.00910155069405505 -23.32922732808970068 12.15698653971175247 26.846191807017191...

output:

-24.104190 49.788183 -84.983595 -182.410882 63.949105 -36.007695 -77.961141 150.144991 20.507903 146.971299 -37.556697 76.724761 12.103101 275.758161 73.787606 9.647038 32.022606 -93.771297 -40.461239 17.733566 54.902860 13.302177 152.375871 -21.870063 56.218487 -80.799333 -68.920622 65.079160 -82.5...

result:

ok accepted

Test #16:

score: 0
Accepted
time: 23ms
memory: 2804kb

input:

241 283
-19.74999113405426954 79.74118587123592761 -66.12366621234484398 23.16116059608839350 -90.51891922181988548 -16.33163848510163518 -55.57111970452539396 13.82071494892652197 0.16803096716331822 -90.49296540512135323 95.43035627948418664 39.25164085774440537 85.85545452213210638 86.25017616286...

output:

45.129941 -55.082365 4.818013 42.531819 -10.492005 17.478256 70.020972 -23.976482 -58.774758 43.265642 53.160338 -92.933321 59.338445 -85.742038 88.212434 -96.807452 44.091584 62.027441 -78.213964 -81.471665 -96.800956 -70.661459 -63.853985 68.217550 31.731127 -79.958964 -99.709239 67.854037 -25.803...

result:

ok accepted

Test #17:

score: 0
Accepted
time: 12ms
memory: 3040kb

input:

234 170
17.48242787918205465 -6.23520728156945836 -58.20418797754270201 72.96983900160395820 -57.35562673978773773 23.50789751949704964 -93.48884020852364074 -58.58187880824885241 -6.27698524763198407 30.85797535881991394 15.89004512612999065 47.23272911191250500 46.93072199569382974 28.367228113369...

output:

25.048809 27.051649 114.191056 -84.578908 -5.935222 -112.462038 -106.567216 55.135143 58.308852 -21.796522 -101.504570 4.105442 -43.013216 -20.974861 13.689307 21.817728 37.929901 29.564946 10.408285 -32.044374 6.719281 -76.758176 -5.902276 -16.586159 -10.811611 18.160989 -75.204257 -30.225619 -28.6...

result:

ok accepted

Test #18:

score: 0
Accepted
time: 58ms
memory: 4340kb

input:

426 246
71.66651361980424895 -37.13107603142846358 -28.40069303830554759 -10.19303738189702813 -40.17751195221595140 80.86389914715766736 1.66282015418795481 26.86828575747655634 7.53315494638275140 5.60609191203955959 16.16504461034760709 19.69955383812136063 -60.18599916098141733 57.91579148537024...

output:

81.897340 -81.476956 -91.375603 28.991755 49.082751 -56.961541 -16.903418 -8.994492 -81.393066 -5.361701 -80.837372 -112.594203 69.609469 -59.611510 -28.185618 -52.701602 -28.973480 51.099931 -62.831395 -38.010814 -17.891101 61.349640 -65.225446 50.008258 25.407701 3.059349 -22.826687 39.977203 -39....

result:

ok accepted

Test #19:

score: 0
Accepted
time: 18ms
memory: 2492kb

input:

190 284
95.33837930303232611 -41.86466971541977955 34.60737779146913340 86.42312952325917763 -62.09721991997125912 52.95486745168355469 -60.47601569570841917 52.36070938755642601 78.02362095964224409 -40.03509120445565372 -83.80692034017873482 -22.71023924588195086 -96.86106094837492719 -40.94740162...

output:

64.133824 85.416033 52.968967 -47.513426 27.058411 44.711186 37.388885 -85.930586 74.399774 4.273763 4.614370 -81.227355 -30.587407 75.288024 51.573014 -37.445038 -90.906795 77.412075 -85.355483 -74.909575 -67.957476 66.320415 -84.345693 18.562571 25.072678 -16.607449 22.550668 83.618126 45.671923 -...

result:

ok accepted

Test #20:

score: 0
Accepted
time: 34ms
memory: 4356kb

input:

355 70
-56.70334470987275211 83.83574979083198286 -5.81321312184857675 -19.10716154891068186 16.13137087617899113 -92.96665311525518405 -24.53366679341564804 -37.69497211956019100 85.70887749812533229 -4.68107417305449758 73.65067115386159458 11.42163179112867510 -40.68482028628190506 99.62559275702...

output:

34.701250 -40.974587 133.202201 199.431392 -215.891597 227.437113 -123.207324 -94.527862 101.329740 -57.925656 -199.606996 -192.413563 -213.229431 -139.937032 127.729217 117.677509 20.159856 -10.771792 172.464266 28.445923 46.030527 -106.331712 139.438406 215.205321 213.301857 -42.690640 130.367756 ...

result:

ok accepted

Test #21:

score: 0
Accepted
time: 0ms
memory: 1980kb

input:

3 256
-78.12078435409665644 -85.08018381555004339 87.27205179005167679 223.75860580275852385
21.40601932440704047 9.30524175131506581 97.69241472114146063 183.70431698693087696
20.78669854557880114 -66.93205030620063667 -81.82893737964754166 71.55186936559947242
73.33954619520272900 -79.946056691508...

output:

88.223100 -57.545165 -59.831479 

result:

ok accepted

Test #22:

score: 0
Accepted
time: 2ms
memory: 1776kb

input:

5 62
65.67809116043918038 -6.95511245917114707 -65.58594103434151634 -24.98238854102574180 -67.64097332382888794 228.65240929183204344
-28.14639570969237070 81.15495829921940185 52.15853584132665333 -60.21000033537702478 17.11911053485283674 185.00177462895109670
97.86755108938794478 -40.32231891383...

output:

-32.568654 -43.891553 32.453979 51.135411 93.167781 

result:

ok accepted

Test #23:

score: 0
Accepted
time: 1ms
memory: 1844kb

input:

2 288
67.61542933343602613 47.25973109181069276 55.13980825108462369
-3.30426408588533604 -40.66692809464620240 167.60932009470940329
36.89409537586234933 30.54619728617115015 86.81691326794248198
-52.65998100097790768 -80.55976539875601361 229.44900096368024833
-36.19022124198538393 -30.51418398431...

output:

94.794119 95.235947 

result:

ok accepted

Test #24:

score: 0
Accepted
time: 2ms
memory: 1776kb

input:

2 285
-73.49177140120454510 -27.45921977176388395 71.97435646756392202
-11.36332241290563161 -67.41256152462275963 79.18940613722345745
-83.02790342763361764 -3.00818194921774307 95.64056891698483298
-76.94037376060684608 69.82459223195203890 168.62048209786297548
-22.19881633373093166 -56.253430626...

output:

-84.134625 -98.642347 

result:

ok accepted

Test #25:

score: 0
Accepted
time: 2ms
memory: 1844kb

input:

3 90
-80.47872995421107589 43.14208059911129567 57.43992229711068376 57.74639348045803899
-28.84828191978905920 86.94632424083388855 -50.35702772129035765 140.97797732099354562
91.43729149053109495 91.54935218332136060 -80.66735336723134253 227.76796873221641704
97.48224581178627091 28.6090833518682...

output:

-70.952021 -11.495005 41.356493 

result:

ok accepted

Test #26:

score: 0
Accepted
time: 2ms
memory: 1816kb

input:

189 1
58.20260994210622130 68.67758954964745044 -19.59536415957194322 -12.42121673471461918 3.64325992063163540 -30.46552521233776645 -46.87401011352478974 88.94910269066244268 53.50792334672570405 90.68612616445304297 -40.41474055830889256 -30.43526744898518643 72.26612568067025677 62.3780757071544...

output:

-1106.420649 68.677590 -19.595364 -12.421217 3.643260 -30.465525 -46.874010 88.949103 53.507923 90.686126 -40.414741 -30.435267 72.266126 62.378076 -55.493304 65.355191 -96.749928 1.167322 -42.140237 -34.138732 -5.667876 -37.613447 73.750227 -43.783538 73.381595 -44.448464 83.848146 -87.380488 -66.1...

result:

ok accepted

Test #27:

score: 0
Accepted
time: 9ms
memory: 3184kb

input:

176 2
64.69868387712475055 -27.91921028014630224 -35.62410375680170205 46.95212302978166008 46.20202416344471885 11.91453444287495245 44.88399112031871141 33.90929126197823962 6.50449209474628276 -22.99563630094168332 66.75691023795118895 98.45710690993425374 11.03714286060825600 38.3844801382377056...

output:

510.305679 769.970544 -25.520719 3.344530 0.284411 -30.792189 16.751013 -28.674622 -22.536490 29.879330 71.777612 58.660097 40.754897 20.016850 44.376525 79.621073 -18.837035 -60.894760 13.965688 9.215978 21.236224 -7.556435 -9.979194 44.876186 5.538150 10.455900 -18.942033 54.193990 -23.963331 -2.8...

result:

ok accepted

Test #28:

score: 0
Accepted
time: 1ms
memory: 1816kb

input:

142 1
2.61917874832131758 -44.49335970449552491 -89.95075503127318939 12.71322648591490179 -52.43006486889640883 30.50437191800213554 34.55669292055185338 -99.07301933969634433 54.67370989914240909 82.56871783156776701 35.28440404839267330 23.24306531642055518 2.32687053783197939 96.1049017411075396...

output:

-1008.123333 -44.493360 -89.950755 12.713226 -52.430065 30.504372 34.556693 -99.073019 54.673710 82.568718 35.284404 23.243065 2.326871 96.104902 -73.303132 -87.010894 -16.795393 99.203048 -86.706758 -55.392803 62.964096 62.535663 77.767606 -58.519538 34.765516 82.747820 -7.007592 91.848804 91.75955...

result:

ok accepted

Test #29:

score: 0
Accepted
time: 1ms
memory: 1736kb

input:

269 1
-18.11564699214282825 48.89329814876245450 10.25015011623035832 25.32240200911952854 75.51469006374665582 -76.79568060899211446 -19.63802183502471621 33.17947978970394729 -48.94987597943094215 -73.78919575498612460 70.21565201752056851 -39.47666698703496024 -21.62615675669682958 86.27099155645...

output:

-1312.594832 48.893298 10.250150 25.322402 75.514690 -76.795681 -19.638022 33.179480 -48.949876 -73.789196 70.215652 -39.476667 -21.626157 86.270992 80.560723 49.410501 17.575125 69.459302 32.834988 72.283265 55.242002 84.660395 63.914031 28.781744 45.721998 -48.031058 -19.657439 14.635360 -87.28122...

result:

ok accepted

Test #30:

score: 0
Accepted
time: 1ms
memory: 1820kb

input:

365 1
23.10990626783959101 -19.34586909615229899 -6.96875501077262527 0.34456297554396542 -68.98648584155537833 45.25601970715359812 68.60001376171371135 36.16207162122566388 -10.16330581679738998 -75.81533995340706156 -6.26078062613449049 -22.83426846904002616 -0.38841161702536908 -54.0019017863873...

output:

-1557.177363 -19.345869 -6.968755 0.344563 -68.986486 45.256020 68.600014 36.162072 -10.163306 -75.815340 -6.260781 -22.834268 -0.388412 -54.001902 5.390042 -52.223808 -90.525359 -27.027932 -22.966907 82.541396 98.019307 -1.444786 52.663515 59.091558 -11.993913 -14.927000 -70.235378 52.968802 26.053...

result:

ok accepted

Test #31:

score: 0
Accepted
time: 1ms
memory: 1780kb

input:

1 50
64.85923222597955373 142.33999735768676942
50.35893895506274021 127.83970408676995589
22.25990417897902773 99.74066931068624342
31.69844616118842850 109.17921129289564419
41.11605242885241296 118.59681756055962865
-14.53903472845199474 62.94173040325522095
7.16711415864197932 84.647879290349195...

output:

-77.480765 

result:

ok accepted

Test #32:

score: 0
Accepted
time: 0ms
memory: 1760kb

input:

1 35
-63.96499900778515979 92.42594280702650167
-97.65209571809808153 126.11303951733941631
-16.94036411896613004 45.40130791820746481
31.27236822709244279 2.81142442785110802
59.66364729851866855 31.20270349927733378
-13.91940073632100905 42.38034453556234382
84.38071434215464706 55.919770542913312...

output:

28.460944 

result:

ok accepted

Test #33:

score: 0
Accepted
time: 1ms
memory: 1976kb

input:

4 40
-78.88287946648640059 -16.62811043870746630 55.42580123616482979 -27.60828113441841936 42.27328257616783702
-4.44671157404496853 76.96604175426281813 -89.54380830984523243 41.72058886140729328 191.53589735859455345
72.64002654217250665 -9.32083710196556581 70.57806486032919224 13.08783991774646...

output:

-70.568456 -19.609882 59.428433 13.537663 

result:

ok accepted

Test #34:

score: 0
Accepted
time: 1ms
memory: 1780kb

input:

5 13
-30.20478063995581408 -21.92814177313326240 -42.44461805817634570 53.26364498645679646 -38.29485661681562192 178.49998050244400360
79.33616890572326952 -36.55946469637649443 70.66985014615084992 -35.10446941162146572 -27.84666177369450679 231.22874657286951106
-36.45626834700239272 -47.12700376...

output:

-64.032669 -44.481989 -78.799637 -83.618857 62.455996 

result:

ok accepted

Test #35:

score: 0
Accepted
time: 0ms
memory: 1788kb

input:

4 30
-52.27220939583720849 -21.57455471727385543 -92.94275176104298453 -2.08091573560969323 222.18345742802782183
31.93363561461731592 79.52292552785885960 20.52784410115411617 -75.35177279991810906 148.93820933276847995
90.67502095256182315 6.20398392101894558 -47.20102188425261147 -70.824847184737...

output:

81.767499 42.549299 62.679087 53.316016 

result:

ok accepted

Test #36:

score: 0
Accepted
time: 1ms
memory: 2024kb

input:

32 3
65.85785916178218713 6.85831609194293890 -15.30976888031534600 -75.30692283941316134 -65.15190131352440517 4.24801038535771625 -39.15741921390454650 -29.82560345081593312 53.72937478242073439 -11.81599701215840525 -4.05299000922640573 -11.25984288284671209 65.93865938982881403 -58.2166489679021...

output:

103.251741 110.225459 305.853734 -86.329739 -13.730494 25.984870 -5.302284 -41.856349 67.835229 -32.597728 24.904954 4.204206 28.990791 -24.933224 -78.767683 -39.988124 -10.663477 -14.769118 17.866192 36.400300 -14.457847 6.728100 18.841812 -35.758500 -32.839094 56.839007 -41.775197 14.871411 -20.53...

result:

ok accepted

Test #37:

score: 0
Accepted
time: 1ms
memory: 1984kb

input:

38 2
-11.00959245879337800 -98.54947151225621838 87.90194151190249272 79.43936287611617786 -74.90189040412091970 -11.83750916384980201 17.01024400929949820 47.32337864655207227 -50.71076964359703965 88.34814581531549038 -57.48722708019155903 69.10969047227212059 -63.64323574333847944 46.273308018178...

output:

396.086173 26.384222 9.370594 28.371173 -65.117511 -57.943344 -18.409109 6.397063 -5.326106 -9.521119 -16.708057 26.040154 23.571129 7.748662 -31.638696 57.252931 -39.770878 44.964228 -5.904840 15.445041 -15.578654 -28.354848 30.030636 73.566405 17.780696 51.041754 9.029783 24.047172 5.418332 37.164...

result:

ok accepted

Test #38:

score: 0
Accepted
time: 1ms
memory: 1844kb

input:

13 3
72.24227664015296568 -18.55475164866786031 -43.11613144157464461 -19.60013839034118632 -49.91944199079070188 56.95177036488686895 36.13145534554163874 24.03291645605759186 -2.76856941433743486 6.55848694395515963 95.16901416342369657 88.75458089509112369 64.94847015738687901 255.715363806645768...

output:

-42.279083 72.811507 131.510635 -30.253101 -43.691737 15.388936 33.767094 24.641209 -26.571452 25.700958 44.236112 3.023326 39.060532 

result:

ok accepted

Test #39:

score: 0
Accepted
time: 1ms
memory: 2024kb

input:

7 3
50.23373989604388612 -69.88780252595731213 -57.22906978031703318 72.98567895437884090 -79.89238323261915298 95.92483451230395985 73.09642064722774535 325.02755887566917181
-43.98084472900853825 -62.70100814910448861 51.85828895150689277 27.97126637152686612 50.19393264295089807 -27.7406974710397...

output:

22.829817 -125.700533 144.288506 16.932013 89.618250 -48.616827 -18.551736 

result:

ok accepted

Test #40:

score: 0
Accepted
time: 1ms
memory: 1912kb

input:

19 3
-95.01393013899175344 31.59516925395340081 -3.67075244178249704 -89.77833166653650210 -18.85584753567273708 -50.84872526166284246 -87.16802093411190810 -32.09059765388832375 61.26348422715224729 23.73763770129502859 -97.41812087078032789 31.23032882316439895 -76.51134982540250462 67.44597527526...

output:

-121.429812 289.654048 -0.436944 6.409452 20.541520 -45.153080 -18.475252 -19.584920 60.869430 39.426690 -29.513280 -13.881070 -78.698881 -68.259788 51.807625 5.047518 -11.250567 24.231180 -8.261564 

result:

ok accepted

Test #41:

score: 0
Accepted
time: 1ms
memory: 1856kb

input:

22 28
62.22846464524795351 5.52663569851108605 59.49083017069543189 -96.51619459249974398 14.39031059433443716 -72.01045224882811624 95.36731661679002059 62.99349464476318872 -65.24414346153614019 -97.86066379894597844 92.43138700007429520 -28.20042145250897647 76.61643639268277184 -57.8696335739639...

output:

-29.922342 -99.744779 60.939773 -50.333277 -0.852151 97.904191 -36.611607 28.170979 67.286374 -92.041856 -71.089406 -93.614294 -41.865660 35.205900 1.882781 -98.874173 -86.206678 -34.927153 -73.568641 -41.804774 -72.732155 -61.273077 

result:

ok accepted

Test #42:

score: 0
Accepted
time: 0ms
memory: 1924kb

input:

33 29
60.98557245693638151 -18.07931759228927149 47.71722790226277766 60.44200815872247290 15.78747444985293669 27.02244757659153152 -68.15148066296292484 -14.75753957216141998 -81.13645066198384370 69.20252380370021683 -84.97403737237749510 42.69315642512637510 -61.23527084314732605 -22.48730719942...

output:

36.642346 29.937644 -42.542531 -7.200090 19.678020 -54.218842 -9.339737 -23.695074 -1.038790 86.110899 -32.104314 -163.541194 -6.587745 45.214721 -86.189426 59.158966 28.155762 -98.034677 -2.595166 95.647571 -74.095974 94.644793 -83.350564 -88.952002 59.750850 -90.214360 -90.069604 -64.477774 71.226...

result:

ok accepted

Test #43:

score: 0
Accepted
time: 1ms
memory: 1916kb

input:

24 14
-17.40138662805254910 55.03045505086637945 49.70539016308549662 15.26128344392927261 77.78369228783481049 75.64393879487477079 -92.13067565639920531 81.94847875525715608 -72.78803589017901743 -63.06606871805424674 49.23417172729224944 -78.33066588806227060 -55.64576453861675986 -94.46348476940...

output:

-8.821085 -47.376011 14.660136 80.748034 -108.328549 51.023759 -8.579641 -44.698161 65.320203 -29.932451 -52.680621 -43.854222 -15.146024 75.653934 -18.182802 -23.020128 -30.723184 -16.333542 -37.382647 -95.454182 41.785336 13.711895 -61.375693 36.768990 

result:

ok accepted

Test #44:

score: 0
Accepted
time: 1ms
memory: 1820kb

input:

12 6
90.76755547853997541 40.86624230264283142 17.87869966661719445 98.08085221620558514 62.38376631439496123 42.38025343316073190 76.29870786465647825 -27.10931954515942266 80.08309062453179195 50.50807728486387305 96.60736437520210984 -75.85430013538719152 315.04833172222373605
82.1123285886446865...

output:

-58.163308 -93.021921 82.602085 21.984385 7.092123 46.322279 56.990594 -74.880242 -38.994659 57.064003 -47.807964 15.597176 

result:

ok accepted

Test #45:

score: 0
Accepted
time: 0ms
memory: 2028kb

input:

24 18
-87.49764639603955629 -47.74586257973560777 48.59043969065740498 -80.41410235408326912 28.89032206299071959 -47.13669365527315591 28.49575702908228436 73.78279256909192441 -13.32054095999075116 50.44405826937537540 -12.24037261107096697 -75.85092891984008645 85.28969143528902919 -68.7066743703...

output:

-26.665211 55.001485 11.052719 17.853332 72.764714 60.847195 47.123614 123.743356 -43.771694 35.199714 -75.255940 64.009857 7.200362 -19.476902 49.865236 83.390487 -92.569740 -7.291594 -82.752975 81.804099 -17.025099 13.952135 74.628569 30.268866 

result:

ok accepted

Test #46:

score: 0
Accepted
time: 0ms
memory: 1780kb

input:

5 1
-98.92874737593162138 61.13121144302337484 -55.35187132540717414 31.04973951571832913 -12.86232323817209533 153.48461134875867629

output:

-252.413359 61.131211 -55.351871 31.049740 -12.862323 

result:

ok accepted

Test #47:

score: 0
Accepted
time: 1ms
memory: 1780kb

input:

5 1
74.45601861721232240 -88.25221705818179885 -21.89425418617103958 51.81808193090810732 -65.37432640384588467 220.12839308526943682

output:

-145.672374 -88.252217 -21.894254 51.818082 -65.374326 

result:

ok accepted

Test #48:

score: 0
Accepted
time: 1ms
memory: 1756kb

input:

2 2
4.14909935574205235 -78.28709659608364291 49.35646372696943018
-45.22408328403919597 19.66777996170694109 106.04657364268864228

output:

39.613308 -43.959988 

result:

ok accepted

Test #49:

score: 0
Accepted
time: 0ms
memory: 1980kb

input:

3 3
78.43191720848898285 -62.52454077645417385 -29.56285570729887979 202.64545693825559169
-94.21198895074385860 -45.13275298277459058 39.17395136772466913 167.87300349011442790
-8.34170007575511363 1.09250804587503580 -60.95208781815404109 173.09105656783955851

output:

3.167807 80.907010 92.206948 

result:

ok accepted

Test #50:

score: 0
Accepted
time: 1ms
memory: 1816kb

input:

2 3
-39.02285862135088479 96.05974306394270457 192.78968611015349666
-92.31646382797036665 95.94080691707665665 202.03332590641781508
80.44236050212563782 -92.11837389867663717 111.53034736239179381

output:

-30.999393 -96.562912 

result:

ok accepted