QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#459262#4215. Easiest SumNyansAC ✓47ms36568kbC++143.8kb2024-06-30 00:09:512024-06-30 00:09:51

Judging History

你现在查看的是最新测评结果

  • [2024-06-30 00:09:51]
  • 评测
  • 测评结果:AC
  • 用时:47ms
  • 内存:36568kb
  • [2024-06-30 00:09:51]
  • 提交

answer

#include <bits/stdc++.h>
struct val {
    long long x;
    int l, r;
    val operator + (const val &rhs) const { return (val){x + rhs.x, l, rhs.r}; }
    bool operator < (const val &rhs) const { return x < rhs.x; }
};
struct Seq {
    val sum, lmax, rmax, max;
    Seq operator + (const Seq &rhs) const {
        return (Seq){
            sum + rhs.sum,
            std::max(lmax, sum + rhs.lmax),
            std::max(rhs.rmax, rmax + rhs.sum),
            std::max({max, rhs.max, rmax + rhs.lmax})
        };
    }
};
struct Node {
    Node *ls, *rs;
    bool tag;
    Seq seq, nseq;
    void up() {
        assert(ls && rs);
        seq = ls->seq + rs->seq;
        nseq = ls->nseq + rs->nseq;
    }
    void flip() {
        std::swap(seq, nseq);
        tag ^= 1;
    }
    void pushdown() {
        if (tag) {
            ls->flip(), rs->flip();
            tag = 0;
        }
    }
};
int main() {
    int n;
    long long k;
    scanf("%d", &n);
    std::vector <int> a(n + 1);
    for (int i = 1; i <= n; ++i) scanf("%d", &a[i]);
    scanf("%lld", &k);
    std::vector <Node> arr(n * 2 + 5);
    arr.clear();
    Node *rt;
    auto build = [&](auto &&build, Node *&u, int l, int r) {
        arr.emplace_back();
        u = &arr.back();
        if (l == r) {
            u->seq.sum = u->seq.max = u->seq.rmax = u->seq.lmax = {a[l], l, l};
            u->nseq.sum = u->nseq.max = u->nseq.rmax = u->nseq.lmax = {-a[l], l, l};
            return;
        }
        int mid = (l + r) / 2;
        build(build, u->ls, l, mid);
        build(build, u->rs, mid + 1, r);
        u->up();
    };
    build(build, rt, 1, n);
    long long w = 0;
    std::vector <std::pair <int, long long>> strl;
    strl.emplace_back(0, 0);
    auto append = [&](int k, long long b) {
        // printf("%d %lld\n", k, b);
        while (strl.size() > 1) {
            auto [k1, b1] = strl.back();
            auto [k2, b2] = strl[strl.size() - 2];
            long double x = (long double)(b1 - b2) / (k1 - k2);
            if (x * k - b <= x * k1 - b1) strl.pop_back();
            else break;
        }
        strl.emplace_back(k, b);
    };
    for (int i = 1; i <= n; ++i) {
        if (rt->seq.max.x <= 0) break;
        w += rt->seq.max.x;
        append(i, w);
        auto upd = [&](auto &&upd, Node *u, int tl, int tr, int l, int r) {
            if (tl <= l && r <= tr) return u->flip();
            u->pushdown();
            int mid = (l + r) / 2;
            if (tl <= mid) upd(upd, u->ls, tl, tr, l, mid);
            if (tr > mid) upd(upd, u->rs, tl, tr, mid + 1, r);
            u->up();
        };
        upd(upd, rt, rt->seq.max.l, rt->seq.max.r, 1, n);
    }
    std::sort(a.begin(), a.end(), std::greater <int>());
    for (int i = strl.back().first + 1; i <= n; ++i) if (a[i] <= 0) {
        w += a[i];
        append(i, w);
    }
    // if (strl.back().first == 0) strl.emplace_back(1, 0);
    assert(strl.back().first != 0);
    long long L = ceil((long double)(strl.back().second - k) / strl.back().first);
    int ans = 0;
    const int mod = 998244353;
    bool lef = 0;
    while (strl.size() > 1) {
        auto [k1, b1] = strl.back();
        strl.pop_back();
        auto [k2, b2] = strl.back();
        long double x = (long double)(b1 - b2) / (k1 - k2);
        // printf("%lld %llf\n", L, x);
        if (x < L) {
            L = ceil((long double)(b2 - k) / k2);
            continue;
        }
        long long R = ceil(x);
        if (L < R) {
            if (lef == 0) {
                ans = (k + (k1 * L - b1)) % mod * L % mod;
                lef = 1;
            }
            ans = (ans + (__int128)(R + L + 1) * (R - L) / 2 % mod * k1 - R + L) % mod;
        }
        L = R;
    }
    printf("%d\n", ans < 0? ans + mod: ans);
}

这程序好像有点Bug,我给组数据试试?

詳細信息

Test #1:

score: 100
Accepted
time: 0ms
memory: 4104kb

input:

5
1 -1 2 -2 3
3

output:

5

result:

ok 1 number(s): "5"

Test #2:

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

input:

3
-3 -5 -35
1

output:

998244349

result:

ok 1 number(s): "998244349"

Test #3:

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

input:

100
-7808082 96278545 91136346 4791987 -36451577 -33596739 -69450010 84481462 -99529162 60949239 72542771 72088996 -35443418 -76531992 -50718219 86231655 -35308791 63500706 82650944 -65252845 13066652 70626553 -54199452 97362467 98696377 36238594 -44542388 -3792147 -2820241 -59459156 -30170137 -4471...

output:

778259516

result:

ok 1 number(s): "778259516"

Test #4:

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

input:

100
43470556 -24635074 29849478 53805691 50607125 -95279733 -7253302 -20078918 2774026 39635460 -52937315 14031619 57028453 65837691 53336763 -14666701 -76024013 -27356769 -87953322 -14621311 98545153 92215405 -68571128 69249573 28558097 -9801652 76030121 -20009034 44053000 74245196 72242953 -627014...

output:

532023532

result:

ok 1 number(s): "532023532"

Test #5:

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

input:

100
-60699225 15381545 2478423 -85840694 -34004120 65663345 -83222264 -88829667 -46161106 78614233 -25290571 -52896583 36957747 56700727 -99374636 -34577834 72202392 -43828613 -20014088 9415279 -56063513 4449046 -23727515 58654170 -80213673 42179357 82019014 -62771120 -80773097 -94504334 -60175820 -...

output:

24346343

result:

ok 1 number(s): "24346343"

Test #6:

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

input:

100
97264577 63116640 79109399 -32005001 -92309006 -2841510 19916133 47951028 -40568967 50214181 58286869 -91979532 -56200937 59982617 14130982 42779257 90773614 -71070588 -75091128 -89311130 59034137 -51418829 -64730204 -81154552 -27561185 -96075158 29343102 35910977 -16100694 73575465 24306677 -47...

output:

727123985

result:

ok 1 number(s): "727123985"

Test #7:

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

input:

100000
16811197 62688349 -98275286 -7582034 79896950 -1642564 84689457 64693647 -63232017 -40825537 65390242 -12619671 -9200709 -36492366 -77540708 45600846 -80383137 61538003 -10446321 -90984592 -12579326 72249861 -80572442 -64503974 -43240144 -1204125 33825946 -78451969 -90483562 -69824917 -952619...

output:

852362329

result:

ok 1 number(s): "852362329"

Test #8:

score: 0
Accepted
time: 35ms
memory: 35296kb

input:

100000
-15965530 49121703 3295669 94422240 -87553042 -4321139 -17892825 -21151818 -2692783 -30847775 52760326 -51706619 -53899224 47990420 -61289163 17487494 -7260026 50780018 17430511 32336827 85187067 -91681644 -63605611 -60632484 98083501 -45227288 -22594797 40067155 -92411062 -26474943 -57345360...

output:

136229586

result:

ok 1 number(s): "136229586"

Test #9:

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

input:

100000
64069397 -81833979 73327921 98081029 -3826014 3657374 36153131 46437472 70137772 -30325110 -2587949 33472599 -118424 -98880992 -5872428 28463383 -22879957 58644855 -44994050 35748112 -62077985 -50534314 31582109 -36940306 56116890 -39831827 -60940027 -81615617 28917441 -46777380 24975632 1782...

output:

667768441

result:

ok 1 number(s): "667768441"

Test #10:

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

input:

100000
-25495416 38209317 25930932 -2725740 75649438 -74699210 10987357 84699446 27307141 76966538 -81792725 -17298657 -96227013 -18029289 16729541 -8632968 -58909218 -64363262 67476565 4266485 -14330733 59645230 -52502599 -39463809 -29448801 82720247 -44763593 65857452 -23388446 -15540880 -93426246...

output:

851875166

result:

ok 1 number(s): "851875166"

Test #11:

score: 0
Accepted
time: 45ms
memory: 35568kb

input:

100000
-2297360 -26896455 25911286 -75270280 -9430894 30490050 4590819 70174434 77202602 -96044504 -1126514 -9652238 59244090 -41396657 -39144110 50556040 94468616 -53918843 -30719912 -68912139 27129162 46304894 38188014 88444800 -50888874 -96493921 -60386926 -55879463 61042981 -32080754 -94421344 -...

output:

138461596

result:

ok 1 number(s): "138461596"

Test #12:

score: 0
Accepted
time: 45ms
memory: 35604kb

input:

100000
-27640245 -58090112 34214951 81549251 35870680 76633874 38506575 -44794856 -13155209 66069860 -19385766 17313360 88466519 88401363 -27042448 -31665875 -93986868 -68526206 -16554475 -51456389 75825769 -62293331 -11950069 51918167 -2610533 -24046280 -87003172 87783324 86591740 95804563 27512157...

output:

443006783

result:

ok 1 number(s): "443006783"

Test #13:

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

input:

100000
78528838 93145055 85240570 22322123 -65012934 30358229 -8354575 14410314 -13874379 -26678937 45609338 -74870404 84458428 -73941159 78109351 45050112 -14858375 78794069 78495350 84563837 728601 -7285411 56600100 -57384808 86931403 64959442 -19751431 -71341248 -73478176 97081099 -80997827 -2708...

output:

739270883

result:

ok 1 number(s): "739270883"

Test #14:

score: 0
Accepted
time: 41ms
memory: 35280kb

input:

100000
-77654449 -30676854 55120882 -93938034 -49368354 26584711 54967557 -78776249 18223568 7748597 -85137757 69790003 -96623049 80322429 -55483190 35388807 68456525 67936545 55308340 -70481278 21694056 88890343 -47455350 84565649 20459072 -49553919 49758175 -55362444 81617758 -74960887 48542896 35...

output:

334579670

result:

ok 1 number(s): "334579670"

Test #15:

score: 0
Accepted
time: 42ms
memory: 35312kb

input:

100000
-47158226 11763405 8409421 6744602 -72788516 14346615 40400274 -17661822 -70860776 34883036 36609743 50326074 28068198 85106048 -55546752 -32886897 -88377928 66147870 44139790 47343777 -40630007 -41099936 42971506 -8702780 -52182780 -42450317 -35568900 -24800068 -72882912 -44309920 -29961010 ...

output:

844928556

result:

ok 1 number(s): "844928556"

Test #16:

score: 0
Accepted
time: 36ms
memory: 35316kb

input:

100000
-2659604 95780808 -63480375 4566243 -17195470 -87536639 -94333524 35796612 1825664 -22976176 -15343140 77041107 17010002 -13897463 35369450 13943512 -2584833 11283985 9227176 -93000596 -56166450 27616185 58908718 64504702 -12103879 -93275943 -5321669 -19905140 67302837 -13777925 25382569 5479...

output:

926062546

result:

ok 1 number(s): "926062546"

Test #17:

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

input:

100000
-33393915 24421886 54592624 -49422763 15848506 93971210 -54875750 -25066216 98010841 -23653080 -92724711 -28067504 -38806669 -78085763 -6247807 28767105 -16896131 50728867 84504546 2732022 55353143 -68382870 85405224 -4203684 1057923 -99634951 21541443 -83180287 51039572 74361926 15822716 305...

output:

563071673

result:

ok 1 number(s): "563071673"

Test #18:

score: 0
Accepted
time: 41ms
memory: 35516kb

input:

100000
89333646 -46340014 31270842 -67885977 -71634386 38131660 7603401 94987245 -78823994 -57681776 -8913045 -80623131 -29062174 26147888 -45009211 -62461915 -61270830 35059055 -47037314 52324768 22600482 3238449 33208421 70386370 47154428 -82106137 -22201223 70512978 -31583887 89981762 97800823 69...

output:

757520434

result:

ok 1 number(s): "757520434"

Test #19:

score: 0
Accepted
time: 39ms
memory: 35568kb

input:

100000
-95320998 32680761 65588013 58090341 -97804345 32994765 41031386 -40660759 -69733335 94125695 82839968 4176339 30377568 -88729959 -47580663 -40186088 85408073 41192976 57493610 -5483708 95003340 -67903477 -21243802 29306189 9944350 -59401870 73699511 21561039 94888826 -94492459 15031489 -4261...

output:

432280771

result:

ok 1 number(s): "432280771"

Test #20:

score: 0
Accepted
time: 41ms
memory: 35388kb

input:

100000
-21998703 29079047 89630940 -2357443 40657014 99319291 17619001 -80755220 17408262 75874436 -29047651 -15104073 4574648 -26458640 -17163388 63795070 72095929 -74664129 82826943 46376390 -14674029 95995307 39362046 93167531 45057655 16060022 -87254506 53696357 -47880292 -63399823 -15891136 -34...

output:

220298064

result:

ok 1 number(s): "220298064"

Test #21:

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

input:

100000
-8684109 8260148 -44096994 97124380 -67126177 -77212122 43271740 -26986149 -81546783 1006842 17247141 18822932 -98760669 90402503 53676917 -12131842 45650290 75757064 -56742672 -59187087 -57298410 60214678 38771643 -33131198 63798115 77259461 86180010 -14684610 98034762 -94268595 81136992 606...

output:

442426250

result:

ok 1 number(s): "442426250"

Test #22:

score: 0
Accepted
time: 38ms
memory: 35472kb

input:

100000
-23384470 50826801 73746076 -94851130 79431810 13431945 -66835194 -57974519 22251961 1577005 -2942868 -59937105 -28644930 -49585447 -71400976 -14100001 -28588846 -45804293 68280829 -32456046 24409934 29836509 44565649 -33440802 41610680 43618622 -97098320 -21133123 97996627 -17713273 25016614...

output:

169328382

result:

ok 1 number(s): "169328382"

Test #23:

score: 0
Accepted
time: 43ms
memory: 35384kb

input:

100000
18767055 8868769 47660427 47111012 78476581 86365849 54202217 -84855944 98053848 -4150345 76306859 -76362613 -93267499 53129605 -10783021 27889181 -14770161 9306900 83194945 -13462550 74280231 15916141 40859260 -27699867 -58216068 -14896412 91917531 -40385341 72492745 23721532 -76176155 -9459...

output:

313946531

result:

ok 1 number(s): "313946531"

Test #24:

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

input:

100000
82390718 -15400904 -47779566 -70612506 85671249 -38788127 37649190 72410965 -73820968 834275 45647384 68471047 -97862970 69719174 7856714 41235300 -56067416 -81586646 -96324871 25271558 -77521478 13280793 35996022 -10430505 -33881106 69509111 -44517250 97813876 -11136890 99338742 83360343 -59...

output:

645892905

result:

ok 1 number(s): "645892905"

Test #25:

score: 0
Accepted
time: 40ms
memory: 35280kb

input:

100000
-4302231 66199689 -77723449 -67820726 56159362 -78756035 -85341032 7896340 -93635370 -76334175 95215676 77154577 -99008278 23291870 83817670 -57329034 -97903295 -29908884 58525344 58873225 76416561 -67847314 86142699 31187289 33227778 -88748444 19222413 -29985409 -13773550 63120665 68300850 2...

output:

741300042

result:

ok 1 number(s): "741300042"

Test #26:

score: 0
Accepted
time: 41ms
memory: 35372kb

input:

100000
-85115974 14825767 -39257963 45328802 98082530 -31628356 -63896973 -59447633 -44505793 67741046 -48614491 76060854 -36157361 -15755464 -76854163 -76392392 54338569 59019980 55555075 -3349750 -15518986 -50193591 -98059419 -47085130 41198911 -22233747 34595917 -32896505 -55442434 60621616 -1832...

output:

659347638

result:

ok 1 number(s): "659347638"

Test #27:

score: 0
Accepted
time: 38ms
memory: 35356kb

input:

100000
87941195 -85899548 16995627 -94775353 -7754788 -18400386 35322313 81592911 11397310 -3204581 -55450932 -24033508 40471851 91615977 -51681934 -13501734 50767054 -51148594 -6186982 -51442315 92855733 89091086 46445966 39623904 -6794796 48933862 -85959428 17222620 -63639977 46364238 48199918 -15...

output:

421467461

result:

ok 1 number(s): "421467461"

Test #28:

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

input:

100000
-18567944 -99130543 50413637 247833 -33337600 -64313152 61231365 88252755 67203697 33965774 -69312450 89621601 75360897 27747528 -88209706 2548945 37857468 -52556034 -77069546 -79689502 -96290238 -73621011 51269021 -74988536 -33860867 -11100302 -70260924 -42518862 61843692 -74510757 37412498 ...

output:

173834724

result:

ok 1 number(s): "173834724"

Test #29:

score: 0
Accepted
time: 44ms
memory: 35520kb

input:

100000
-26573000 -19811894 65430587 -61946422 -89926666 88242316 49606933 23719254 -66895862 -34430375 36873679 36831213 -32522333 17567500 -33192957 -880460 33555325 -98077130 -16937621 -75300461 57982749 77421573 89225622 61056619 37231767 -96976782 24894213 6957808 84805521 12727256 -58144342 370...

output:

628446931

result:

ok 1 number(s): "628446931"

Test #30:

score: 0
Accepted
time: 46ms
memory: 35388kb

input:

100000
89756521 38925314 -45713610 14682549 -81796265 -90730316 95339985 -68957590 -24864854 99185995 -66266255 -90915896 -77990724 -69518547 87195929 -23103845 23063553 -87557897 44939803 74677174 -68444917 99750142 -45096860 -5087222 -5014963 30264284 -82524212 -17099520 93465320 -32230189 -192155...

output:

354237894

result:

ok 1 number(s): "354237894"

Test #31:

score: 0
Accepted
time: 36ms
memory: 35388kb

input:

100000
21136413 35322276 -76088308 78803120 36032497 -3604488 -1959827 77149129 63358275 14821076 29784510 80105979 1496573 66378568 61232201 72465583 97108815 -18961737 -94933718 96179485 -51193260 40394299 -51068133 -8021414 51438337 -34304453 5143634 84889521 5656736 -95723132 41080087 -65350971 ...

output:

699534661

result:

ok 1 number(s): "699534661"

Test #32:

score: 0
Accepted
time: 46ms
memory: 35520kb

input:

100000
69009002 33038394 93966016 -39807490 -5557708 61635477 -55660945 -8156345 -63806194 -13867697 -85236570 -46615291 90379378 80641300 -36331601 -23589856 -80186032 62249742 76154208 -52199202 -83138793 13060072 -96194274 58908820 -47544922 -65866171 5684224 7006457 96326579 62995625 -19049583 5...

output:

106402363

result:

ok 1 number(s): "106402363"

Test #33:

score: 0
Accepted
time: 42ms
memory: 35476kb

input:

100000
61039220 85201990 39437893 -44135847 -55698205 87824579 -22710022 -14079238 30073760 -77728523 93528256 -14600025 25047007 78220247 -56421353 -32856813 33813988 -34731846 63834914 -14408901 14765419 -15288249 -26305509 -18685636 62529705 -48768798 7681747 -79753787 -4676951 -10942833 55703928...

output:

244652813

result:

ok 1 number(s): "244652813"

Test #34:

score: 0
Accepted
time: 35ms
memory: 35568kb

input:

100000
75226894 32132727 89984778 60823937 -50512350 76968273 51142562 -15787178 -69926679 -32139387 -13021419 -30200134 17467305 -57167313 93683861 -95496572 -67845269 -86547493 77883350 -29044677 -79848858 84817039 32761192 -81257233 -30724784 33798317 80795200 63799354 78506792 71594832 19402742 ...

output:

492926862

result:

ok 1 number(s): "492926862"

Test #35:

score: 0
Accepted
time: 39ms
memory: 35480kb

input:

100000
-60772301 50878646 -66153583 50218952 -82564267 -58270538 -82470217 19219955 -84224604 -67352061 36952831 91350787 48578440 39821824 -37885511 44564414 53019591 -22133701 -83531966 -76515627 62510204 73280769 -73351061 -8879961 -21371920 -28069866 3351932 50356937 30221382 -66672773 87027097 ...

output:

988809780

result:

ok 1 number(s): "988809780"

Test #36:

score: 0
Accepted
time: 35ms
memory: 35468kb

input:

100000
99926306 -56479313 -77691287 30020152 -44869154 32901880 98090300 -8128108 -36137463 71557972 40447065 -31279776 -73208398 -20024914 -6521220 73461251 55499459 92194249 68719207 29761429 72552643 -43126725 32678890 95093288 -98354781 -72571639 89726729 15133605 49451952 -9009691 -25316690 -68...

output:

496978923

result:

ok 1 number(s): "496978923"

Test #37:

score: 0
Accepted
time: 33ms
memory: 35580kb

input:

100000
75884781 25419096 47639903 51638847 20917267 21931604 3095206 90131693 45220131 -63309137 23442446 -1095033 85215390 -24559194 -77453406 47962481 -37350270 -57637417 46122556 -18621708 -1473966 -89976471 -51191331 20546779 -16631632 -69660374 26580522 34818194 -77493961 66577017 89848081 1587...

output:

239473768

result:

ok 1 number(s): "239473768"

Test #38:

score: 0
Accepted
time: 43ms
memory: 35476kb

input:

100000
-2847341 86513848 8946581 -81038319 48651562 97863195 -53597114 56092509 6736576 -81417832 69103702 40788678 -97049836 -45753535 -316872 49276829 99014754 26200088 56126148 96038296 65708381 -31431830 -35131479 67209736 -81036075 -61803691 -15470704 81851985 25716172 -1989678 -84138101 -31094...

output:

46351614

result:

ok 1 number(s): "46351614"

Test #39:

score: 0
Accepted
time: 39ms
memory: 35516kb

input:

100000
-3019690 -6634566 72506119 -11052146 62576084 93385833 8361639 -15527397 -85931058 89949758 86811413 -52459767 39391320 54387439 28579858 -22418181 68620986 21621410 -51443788 -98091792 -59270946 -24366752 38747893 79988457 -87119234 -89087880 21354363 -98459325 -66506630 -82213918 -46633375 ...

output:

364438303

result:

ok 1 number(s): "364438303"

Test #40:

score: 0
Accepted
time: 45ms
memory: 36568kb

input:

100000
77564281 -77568757 85839561 -11854311 -35490885 24217304 -28133287 -49911727 -43856712 -11598102 37015614 72036655 -99663231 21981302 16551887 32319876 -16190859 -18192736 62949716 -46603930 78202116 -67204615 -49877931 -75597053 47064480 -34161363 66773050 -37267708 -187749 67183895 28552316...

output:

481883088

result:

ok 1 number(s): "481883088"

Test #41:

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

input:

100000
-7602659 18851227 -8179987 -91557179 35648784 94055839 -38894109 -48278049 -94366781 35142530 78435834 29351062 -67366979 56131997 -77660280 -23679328 2423899 -98908321 -13721110 -15732071 -10199781 -63236544 11956286 56682281 -82074537 -73103041 7927699 28842453 -375406 56566039 75031822 384...

output:

527880699

result:

ok 1 number(s): "527880699"

Test #42:

score: 0
Accepted
time: 41ms
memory: 35584kb

input:

100000
27288513 -78890585 -23666705 70681265 -61744200 -19927481 68648290 -96287422 -84096652 -73205472 -59050196 72540053 65342465 78380640 -77026893 -28422918 30172524 -43672909 31562940 60142923 -34230616 -47920883 -15143404 -46006958 -74656378 -98737451 78152436 -97153743 -75076967 93699667 1989...

output:

218611537

result:

ok 1 number(s): "218611537"

Test #43:

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

input:

100000
35970699 60476511 -66656016 -42525438 -65326725 98826026 -38957773 75228482 -29303856 -47066683 -37642824 -34141485 -10919396 -66198006 39297882 -88602652 -93075846 -8914379 38038699 -33812699 26601308 92118024 -44125767 64838 -23772924 25161736 53666022 -49132646 70051471 71878500 44858283 -...

output:

611531248

result:

ok 1 number(s): "611531248"

Test #44:

score: 0
Accepted
time: 40ms
memory: 35276kb

input:

100000
87942194 57364159 53980419 -33521895 46747281 6458683 -37057699 52355370 -5806045 13957269 66186707 5413548 -91225000 -16209357 -58150057 -3244965 45753519 -15665908 104691 -33401738 -98537724 -45711120 38922071 53028216 -3310627 -81145447 -22161984 -30654812 27439649 99405911 -40202885 11205...

output:

651833502

result:

ok 1 number(s): "651833502"

Test #45:

score: 0
Accepted
time: 41ms
memory: 35376kb

input:

100000
-15624908 -22919436 -33515425 -85019251 61282693 63823751 -18142557 -15246396 73253808 89562527 684242 -17042838 27108458 29767452 97903585 39882766 28350864 96587186 -38427463 -29682608 -46847435 -59853237 15023214 -8736875 29631742 -34061233 -14379519 -58528310 -15239922 -22012788 -98560337...

output:

383536658

result:

ok 1 number(s): "383536658"

Test #46:

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

input:

100000
12118446 -63590948 -7106108 -1583310 -67029247 -3865401 -50902942 -85505549 62301410 -1206108 39390224 -9391306 -78606257 -95145079 35920747 55579924 -94730852 -56800924 -91945922 -14293256 -98462270 61195834 -61151813 -62763098 85244279 27489211 -12925761 28027997 90419620 -72201854 -2660389...

output:

145262156

result:

ok 1 number(s): "145262156"

Test #47:

score: 0
Accepted
time: 43ms
memory: 35276kb

input:

100000
-90444291 -74280265 15317127 -81412480 7504669 -30962938 20272366 -89367735 25058959 70878812 -51571915 38278404 55095851 -94058251 -98581233 -86156202 67704495 57944787 -2324583 38438560 62812960 -47401916 88544532 -7617726 -21119925 14970102 13423622 -42681628 56405040 -80725718 79766005 -1...

output:

490779334

result:

ok 1 number(s): "490779334"

Test #48:

score: 0
Accepted
time: 30ms
memory: 35404kb

input:

100000
-23833585 -69464500 -52170768 53463979 -71112201 63408833 -86046139 -33796886 -59712162 -64985720 -22702614 -97721005 2926905 -72385752 31054847 -10490858 38625839 50269944 69051147 46102718 -24583143 -36327221 -16797567 35647689 -40575401 76497331 -96129821 65643657 -45733781 -62145869 -9783...

output:

307078078

result:

ok 1 number(s): "307078078"

Test #49:

score: 0
Accepted
time: 38ms
memory: 35568kb

input:

100000
-84738751 -41705841 -96967882 55659376 -16446447 -50079927 51867741 27960677 -27410109 20411657 -40533543 95156539 65387258 76451961 53345277 -37645558 54704801 34534420 811802 -26514317 -75574995 -85455975 -58205592 9777125 52380260 53046556 150653 -79259667 43917350 -488634 -89596708 501227...

output:

638487831

result:

ok 1 number(s): "638487831"

Test #50:

score: 0
Accepted
time: 29ms
memory: 35404kb

input:

100000
1207721 -36101712 52804624 -70377526 73521822 45539183 40048260 -87196516 50562674 80697490 -67281932 78599284 10229694 79074443 29769869 -19563723 -30783133 -39583998 -74495484 -66308592 -26108967 26225113 -3605344 37532831 -17208211 52690871 94319562 -76485268 -60878117 -66391174 -38657551 ...

output:

187663901

result:

ok 1 number(s): "187663901"

Test #51:

score: 0
Accepted
time: 30ms
memory: 35580kb

input:

100000
-72808805 90565947 66165353 -88346960 82388437 -81151681 90794461 6099761 -66008316 22580104 -47190369 -22679004 64767796 53836965 -23416997 1229111 23252159 69355196 -5104674 -5327663 -84759562 47123724 -59979616 70280832 -99889921 -74144770 83336836 1689021 -28350056 21650122 -59029221 -919...

output:

136187796

result:

ok 1 number(s): "136187796"

Test #52:

score: 0
Accepted
time: 43ms
memory: 35320kb

input:

100000
36834976 24124237 66600624 4030477 -46528466 -50232826 36900961 -45903238 -75616363 -77367689 13930136 -52971351 -43184647 68088748 32535667 -73765359 -84833014 -53537858 -59763258 -85586993 24399865 11810329 -69073073 96063569 80415388 -68933722 19298645 94137453 -19441198 24606024 -74535911...

output:

194424127

result:

ok 1 number(s): "194424127"

Test #53:

score: 0
Accepted
time: 42ms
memory: 35372kb

input:

100000
80269571 58260274 18959312 87256834 -19204327 -46982108 69933985 83501842 -55114116 23807043 -65391709 74964813 8793334 -7173970 43445813 68106625 -78404201 71625928 -92425784 -26176831 25863975 -78902528 86388848 64932081 84711402 45294259 -11448401 70818245 -51711971 -75905805 -46012803 536...

output:

992833523

result:

ok 1 number(s): "992833523"

Test #54:

score: 0
Accepted
time: 44ms
memory: 35360kb

input:

100000
69200179 86400762 55047009 85497488 65271202 76388067 -52609053 42060803 -16187357 71850053 -40373008 -10457343 14673766 86558901 75305081 57996802 -18950147 28721889 -60353466 34120179 -91215185 52590122 94756911 -29893418 93040005 15480029 28368544 -74345310 83891637 87922344 -33767871 4502...

output:

626557861

result:

ok 1 number(s): "626557861"

Test #55:

score: 0
Accepted
time: 39ms
memory: 35280kb

input:

100000
-51380936 27657571 -57994162 30193827 -83519701 82457911 29251332 -67581642 -54077860 -6169264 40519864 31247831 63519327 -34507889 -74093420 -2351856 64417170 7710761 -26744675 57353720 34982841 -48112292 85552258 97924473 46639136 -20343732 86295507 -43725540 -59192985 20932696 28647130 -35...

output:

931641559

result:

ok 1 number(s): "931641559"

Test #56:

score: 0
Accepted
time: 41ms
memory: 35320kb

input:

100000
-26401264 12561973 53416957 -75590014 7173273 17133958 -6991309 -37313548 -17155307 -76060768 6265444 19493304 8135345 -52196570 24937107 -89770953 70972384 -8212506 88304296 78093649 -29066260 52596379 26264219 37026478 82710836 -50780698 -2542210 1132788 -11613963 -13160060 -86427802 -96363...

output:

163753768

result:

ok 1 number(s): "163753768"

Test #57:

score: 0
Accepted
time: 44ms
memory: 35476kb

input:

100000
19955868 -97125774 -86413347 -21814818 46791412 -70724443 25240164 47899988 12698284 -13164725 -85997970 -49671079 -97673616 95620897 93687403 38324335 25530796 50290871 85740267 29310659 92996714 -12084546 -98043423 8840038 -40750549 -14364183 98868013 -15881073 3818700 63133993 -47029877 13...

output:

860686884

result:

ok 1 number(s): "860686884"

Test #58:

score: 0
Accepted
time: 40ms
memory: 35300kb

input:

100000
18946138 -91134527 98959089 -31644603 63141998 -28819641 -9165996 18964666 -65099355 59969503 57719185 -53763435 67768491 33611160 -68743973 8320301 -95176529 67542747 47133821 -91678937 -3110082 6821064 -6723276 57049482 32541513 85912659 6999743 22204942 70584485 -39730380 46700377 -6556434...

output:

811775041

result:

ok 1 number(s): "811775041"

Test #59:

score: 0
Accepted
time: 36ms
memory: 35512kb

input:

100000
-96109627 12194887 93772456 -12193614 -25323075 -61255473 45074186 -39501674 -55729365 -62398006 6474715 13782480 -14392501 -56935922 -7805093 -74832894 51597339 27191801 96864471 -75994462 74589604 -34404387 -47515597 43561632 70895443 -15510685 4913087 -23529039 -12428765 62336539 -36643481...

output:

774177460

result:

ok 1 number(s): "774177460"

Test #60:

score: 0
Accepted
time: 38ms
memory: 35276kb

input:

100000
-61240304 60754505 -4600401 41089166 39508053 -2626962 -29029558 -50356506 9182782 -7076442 84163601 -55625719 -80369045 -52163624 68040171 -68364204 -47808762 72539093 -74391947 49419310 20261479 -41844960 73095657 53329096 -1156783 43368 20001039 12688462 33036480 49805810 -71748769 -660398...

output:

636234361

result:

ok 1 number(s): "636234361"

Test #61:

score: 0
Accepted
time: 39ms
memory: 35584kb

input:

100000
23547557 -53025946 58721088 -19644616 41449709 -78247510 89796530 96384100 50035380 60838905 6873320 -49463205 39605783 89142050 -64365767 -93591260 -48435158 -89273935 76973422 -54951076 87747954 45825901 45633820 73296230 -16966112 19921304 -25632077 -82154495 -56542928 -31588223 72112797 1...

output:

783662844

result:

ok 1 number(s): "783662844"

Test #62:

score: 0
Accepted
time: 36ms
memory: 35356kb

input:

100000
21837085 68329083 83635778 72975135 52200367 92025540 -88791091 42285159 55667387 70757554 -41968381 60574579 70043041 11327892 28486205 91768544 -76079046 -42919928 -42239202 -67557340 76340174 64947863 -47481671 -76840594 -20023908 -69280779 34773387 -97712514 -62397993 53040182 -23030100 -...

output:

378992613

result:

ok 1 number(s): "378992613"

Test #63:

score: 0
Accepted
time: 30ms
memory: 35560kb

input:

100000
-92353039 -73614327 -51107115 83851887 55461777 63173816 92568042 -5795612 -46426197 90658937 -13723445 -59777260 69978990 -77680049 -31180482 23430826 99033392 2863158 1880497 -26052931 5088070 -75079100 -16973944 -71494522 99566394 45009660 88145245 -60748540 88573154 59243023 51489528 -289...

output:

400600619

result:

ok 1 number(s): "400600619"

Test #64:

score: 0
Accepted
time: 38ms
memory: 35316kb

input:

100000
39488150 -85091082 25604509 -4691687 62540360 -33050273 23666395 98959341 42362840 -97103416 -59556911 -5895264 -68049374 13432051 15356280 -99634258 13244879 38163742 4804521 -30722593 -17683065 -18986875 -89169508 33432657 91949763 72205281 93008773 70917288 46695825 -51535804 -95969085 -52...

output:

290460449

result:

ok 1 number(s): "290460449"

Test #65:

score: 0
Accepted
time: 41ms
memory: 35564kb

input:

100000
26037963 -31697761 72096741 -33427483 -19243680 -63668691 -14632046 59156614 -32981645 -86350303 -46018214 -13063334 -10676076 -64288385 13383505 28784652 -86442538 -61484734 -65237803 75495309 79274056 73851406 97454154 -94960628 -72968291 49777874 -78984117 -83466742 -12007021 -6866198 -715...

output:

273880238

result:

ok 1 number(s): "273880238"

Test #66:

score: 0
Accepted
time: 38ms
memory: 35584kb

input:

100000
88674307 -87169929 -3080478 -15935938 -36041347 35473595 44122973 -77022296 86674120 -79059470 -97857362 86218200 32571920 -19916194 16051538 -57290381 82602842 33700492 36452996 -31689636 -93811548 99186790 38719492 -75877252 44459718 13082783 75139475 95505115 -8742221 30635193 -95066156 75...

output:

641330425

result:

ok 1 number(s): "641330425"

Test #67:

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

input:

100000
-77456165 -38085300 -16705194 -29978656 47713099 21362261 -50852823 71469418 -45221085 -64326644 21004718 -70194230 98283683 -60397064 -11289264 69335379 -64859266 21840833 91122724 22935769 -22019542 -26756492 13455537 50608534 32200889 -9613269 96818792 45106989 -23093506 -51568557 36864629...

output:

648942243

result:

ok 1 number(s): "648942243"

Test #68:

score: 0
Accepted
time: 40ms
memory: 35276kb

input:

100000
-59588205 -46459811 91941958 54678666 89341289 82448280 -27025347 -44950470 -92464849 -78039388 -9534961 -37522544 -11734362 -80455841 89411326 1623983 15091957 76503731 -404846 -74448198 -4011533 72829426 13898009 22733711 33342021 -33802997 -77462676 -33940553 72787993 41546348 -43340468 68...

output:

669196863

result:

ok 1 number(s): "669196863"

Test #69:

score: 0
Accepted
time: 41ms
memory: 35352kb

input:

100000
-1600912 28940348 -67602612 28903270 824827 -94593984 25120866 48208604 20340483 -57228844 -12721117 38954100 -61845343 -16580388 -60651367 -11799417 60326395 -7893910 -69858886 -68781300 -89316864 -26623031 -22596823 41713176 7897015 -54629659 -91204777 89424881 95614917 14319448 83711937 -2...

output:

882404294

result:

ok 1 number(s): "882404294"

Test #70:

score: 0
Accepted
time: 32ms
memory: 35580kb

input:

100000
15765717 -45224194 -6186368 26021346 92315738 92502379 -20673642 -1762207 -86294609 -30081396 95207478 78563883 -28965259 27688132 -58440930 -17530466 59584095 63798795 -67180590 -7781432 -80775809 87963249 22373449 85432005 50179527 18750992 -21861583 -73162547 -32167646 -93491865 54046580 1...

output:

639751463

result:

ok 1 number(s): "639751463"

Test #71:

score: 0
Accepted
time: 43ms
memory: 35468kb

input:

100000
-47123346 98302558 -19637403 -27580033 9326990 74746334 -13293492 -188068 36107115 -40234672 -20318231 19734408 16613231 -50393232 23826948 11858641 -45941271 -28313389 12938361 73411958 -92915417 -73394384 10478972 95148859 -42791095 -49899968 19062891 35089995 -19451347 85392557 83070000 41...

output:

258803573

result:

ok 1 number(s): "258803573"

Test #72:

score: 0
Accepted
time: 39ms
memory: 35512kb

input:

100000
72235409 43577503 -86692326 62385922 53445118 21808160 69842579 79902742 76796108 29913359 96787191 -17681429 -78813312 73233749 -24359058 -33767018 66778021 -39139934 91171347 75581042 16058149 -3419444 71510120 -35096639 -39120841 1268700 -81965598 5147215 -63048353 24394717 21901003 -44827...

output:

100574507

result:

ok 1 number(s): "100574507"

Test #73:

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

input:

100000
29346446 -15346568 -89080040 -5595761 10640721 -46843359 1366267 97458831 41397658 -21050087 84669509 -2302996 -14604246 -60958689 -76378468 -14972872 -60359608 -40271484 -32324326 43357393 -2716922 59121952 99680123 -70188225 85343482 39606185 -31649618 -49478637 -62833080 -96513222 76976841...

output:

263626165

result:

ok 1 number(s): "263626165"

Test #74:

score: 0
Accepted
time: 40ms
memory: 35372kb

input:

100000
-24762718 -49309738 -37559011 -29265431 -4708245 -5522693 12693589 79185547 -95413024 59329580 90573860 -47778627 -85554659 16442448 -78855310 -8739416 -13344062 351454 -59087392 -58904757 36856214 10431107 -25637816 -69279937 -91372740 15950146 -96271472 -31949792 18096864 -92499868 96174508...

output:

955792292

result:

ok 1 number(s): "955792292"

Test #75:

score: 0
Accepted
time: 36ms
memory: 35280kb

input:

100000
60898578 -20632191 -66834564 97252304 29016433 65890003 16249722 -31051196 -61536309 21484679 -74591774 -65454945 89109742 77590658 29932464 -37902316 -85378530 46928427 55151950 -22140450 -46862933 39460782 -61357948 -16398684 90491104 -57368841 48922710 -34338551 -37395681 -748570 49046884 ...

output:

422140860

result:

ok 1 number(s): "422140860"

Test #76:

score: 0
Accepted
time: 35ms
memory: 35464kb

input:

100000
-42513086 -76506610 84342731 42828331 66425437 71857278 -75898133 -77424396 -96306834 48298865 -28483741 32418905 87852245 -47059686 19903905 2780009 2927715 122904 -12746336 30401800 -4471059 10159161 23084883 -65721521 -47377122 78411537 -17840334 96381411 -10456386 5904445 25485268 -889071...

output:

897975363

result:

ok 1 number(s): "897975363"

Test #77:

score: 0
Accepted
time: 44ms
memory: 35372kb

input:

100000
14496693 -95193960 -22378015 66807397 -75698688 -40594066 -71308653 21325677 -64274447 5439802 -29843001 -91692429 33946472 18651465 85988235 -24300533 -73302848 -64921056 21680686 40383828 -36280427 -61890259 3702600 99985191 -48788982 -81527393 -11288061 -78458604 91945654 31436256 88352093...

output:

414316811

result:

ok 1 number(s): "414316811"

Test #78:

score: 0
Accepted
time: 41ms
memory: 35472kb

input:

100000
95147931 15407038 61875607 -77755076 -23372867 -48747294 86985665 57447225 49037799 -44453660 -75681842 -92228797 -63009940 89305892 -44157892 89275941 -727686 33148503 -5976638 -35588445 -51004882 -66376308 90893940 -38695076 -40693580 -20596127 -67793687 4946091 32730566 -94779823 48984510 ...

output:

700491011

result:

ok 1 number(s): "700491011"

Test #79:

score: 0
Accepted
time: 33ms
memory: 35524kb

input:

100000
2426448 -39643437 -57978490 55769592 10345875 62867938 60223594 -46915538 72420479 -39254772 67336576 -66532586 17153403 14235414 -47055203 -41633865 -42548073 89332536 -70031200 79178723 -71126230 99000564 -69617534 -31863317 -87952437 -57987879 60043502 37373995 -31229525 9285837 -5085218 -...

output:

597276745

result:

ok 1 number(s): "597276745"

Test #80:

score: 0
Accepted
time: 41ms
memory: 35300kb

input:

100000
61672720 -65655202 64458259 15572609 10655972 34208220 55841522 31249143 -11506834 -78714582 63057790 83839081 -82335696 -40402362 -31679457 13031906 68766031 34547066 -46845144 70137785 58846535 17761111 42972060 41699432 99680172 -47500963 54855806 76359212 42776047 -43698095 3948576 180899...

output:

492443181

result:

ok 1 number(s): "492443181"

Test #81:

score: 0
Accepted
time: 43ms
memory: 35464kb

input:

100000
7985679 44932507 6892045 -47622654 55838335 51903645 50216036 14652036 -31167558 30060774 30820233 -69924249 22416780 -52644596 18244483 8790906 -48704610 71048024 -88070048 89331907 80615823 -50543159 -38846013 15341742 21105923 52014890 14773922 33411370 14935575 80896438 70731672 -77574394...

output:

635101114

result:

ok 1 number(s): "635101114"

Test #82:

score: 0
Accepted
time: 42ms
memory: 35472kb

input:

100000
-83672090 -35851739 -2046854 -54159863 -39554429 17381536 -51024749 18797911 64936154 46939205 63527898 -6658534 89656336 -18857221 40188489 -99530970 75840389 -59270695 61909005 34656686 -8480391 93295407 72114660 -91271502 -38620094 72719757 -75304502 -63438384 14814316 -54451759 -22624911 ...

output:

229628328

result:

ok 1 number(s): "229628328"

Test #83:

score: 0
Accepted
time: 39ms
memory: 35320kb

input:

100000
-36512161 -14237043 67610655 -12895117 -36888449 -98903994 -8701476 -53626423 17927022 -51489051 88721994 53961498 -58610797 -6941546 -8251959 -89906893 -51314304 72060697 96080646 24878358 -24994074 -7295096 -21573669 -84523212 -12891883 -25801395 -52263153 -7025094 91762373 -53488207 -18074...

output:

842182176

result:

ok 1 number(s): "842182176"

Test #84:

score: 0
Accepted
time: 36ms
memory: 35320kb

input:

100000
-90183805 65843755 32031425 18145969 12271368 32320343 42445754 4368397 95801294 -36776250 90365608 46790117 -42259437 63802272 -25166669 -32871938 -9891150 3941185 -96728824 -53564996 -15708679 23392222 63922914 18591828 -63035638 20417288 -17148170 29581006 -25387115 -83700304 33640038 -382...

output:

904987858

result:

ok 1 number(s): "904987858"

Test #85:

score: 0
Accepted
time: 44ms
memory: 35400kb

input:

100000
49152221 -76270643 89590397 -13678018 42938571 -29299823 24883486 -32992995 98980433 -39703833 -24902443 -63077293 82345460 -58153146 76559902 26526370 2333035 33960503 86870362 2838997 68623003 -40403717 -69879789 87191540 69508935 8659274 57940191 95065971 83972104 61952439 -99507873 222073...

output:

27813120

result:

ok 1 number(s): "27813120"

Test #86:

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

input:

100000
9033187 18238935 -81332612 76210899 99102286 51348125 -51252559 30023262 -49069425 94765829 28070363 -35279805 -96459481 -72248261 -35512353 -10454090 -61061016 -60373652 58275480 21387417 -30429302 -60980322 7777600 72550960 5712081 35946859 99687470 -78188751 -87807932 -59591208 17758615 -7...

output:

204823447

result:

ok 1 number(s): "204823447"

Test #87:

score: 0
Accepted
time: 46ms
memory: 35388kb

input:

100000
68014203 73894414 -68567264 -24229979 33382069 83036347 -67187093 64550135 -84493912 -71463768 81243647 -27714676 -68877133 -95984991 -50976184 -45571619 -90328464 -26691357 -92578189 -85772415 -56859131 70037058 -67471941 18613708 -16250346 -2278340 -38117728 -25126997 -51764063 86755355 -96...

output:

739151932

result:

ok 1 number(s): "739151932"

Test #88:

score: 0
Accepted
time: 40ms
memory: 35352kb

input:

100000
17043294 95575132 16911718 34781268 32239081 37075738 40688210 -56876316 44080889 83267277 -73211931 -57552126 -50249933 -92041761 9913960 -37507622 -55148965 55136270 -48747093 -55821124 -85403780 17215898 -34116317 -79350450 75047435 13323273 64814672 -49733096 -92022670 75127091 34573516 -...

output:

652531672

result:

ok 1 number(s): "652531672"

Test #89:

score: 0
Accepted
time: 36ms
memory: 35556kb

input:

100000
63400244 -265694 -79633054 -32021412 34855288 -58868370 7302499 -87651528 11601751 -92594354 -40488822 -15165875 -30057235 -16278427 -39124988 -46223300 10768580 -50728801 12297403 85101410 84448980 -3451478 -53149444 -78375565 -22635209 96857885 -26819595 -75634987 -75343704 -17285576 -47031...

output:

854626050

result:

ok 1 number(s): "854626050"

Test #90:

score: 0
Accepted
time: 38ms
memory: 35316kb

input:

100000
12800614 9969795 88572558 36572989 25765239 -86189972 -14958032 8387999 -12891188 94860716 -73617187 -60734858 94806909 45823675 -29701756 40085200 90078044 42867505 67254994 -15015587 -56684563 70171744 -78764396 38744406 61697350 81845611 -1796670 79256930 -81247745 -52944241 62444330 11007...

output:

619899190

result:

ok 1 number(s): "619899190"

Test #91:

score: 0
Accepted
time: 41ms
memory: 35472kb

input:

100000
73126605 77901497 -17076955 17195819 73728491 -74287758 11272133 13164853 -21028153 -56747259 -11403934 -66403652 -89202711 -62411473 -94567268 -22676410 -94285534 85051548 -78731556 93403334 61809208 7020816 -13099923 -83993180 19599805 14908525 -52439265 -12521773 -44283095 -29731254 -19828...

output:

692946069

result:

ok 1 number(s): "692946069"

Test #92:

score: 0
Accepted
time: 45ms
memory: 35328kb

input:

100000
14280262 -27472396 -39659000 22991279 -82258991 -82456034 -22157560 -79177758 -33159377 -8587284 -73092598 31618030 -71674860 71456131 -55839233 52167216 -26972503 -47959187 -97437293 30544011 36243727 8946788 67688195 22734823 57400702 50446470 -83908849 59720899 39675811 6249214 46708189 -2...

output:

4848733

result:

ok 1 number(s): "4848733"

Test #93:

score: 0
Accepted
time: 38ms
memory: 35568kb

input:

100000
-79732361 85807076 -58358514 -44430870 52300201 -589024 -15076144 94234287 -88647453 30893456 -37116169 -84029175 -83752340 3118277 -12228999 48837372 94002912 78253360 56718723 36431613 -7357440 -51548465 -76401754 62440534 -79082941 95164474 -60042253 -94805762 21779366 -61883961 -11910047 ...

output:

116384815

result:

ok 1 number(s): "116384815"

Test #94:

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

input:

100000
53266853 45306201 84065697 -86221597 -63640762 20317343 -74352994 78312025 76499028 48373841 77882520 46670238 -32273079 -25588648 -41758987 -9128775 -46708771 28461108 -81451447 86988774 -46041869 73788377 19246382 -16185204 40125296 -62770530 13336032 -84680652 -29179900 -38851511 -79950739...

output:

419522714

result:

ok 1 number(s): "419522714"

Test #95:

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

input:

100000
11139728 2377689 34450893 -29825411 -69020796 60013199 42839539 56977510 -60882452 42559715 -47885888 -73061571 -20904540 -54027103 4469745 -31384953 -5624317 -15901053 -21393998 -30079635 89922800 -82341758 3265747 36017588 19042340 -69794335 46253873 -42917671 6148989 72459829 -46975201 -36...

output:

804824512

result:

ok 1 number(s): "804824512"

Test #96:

score: 0
Accepted
time: 39ms
memory: 35520kb

input:

100000
-35529733 -35171968 10964500 -62663082 -78629701 75904867 -87978713 -71220672 -68295869 -74718014 -27565454 -4857413 78051896 66000898 27398062 27393694 -21591387 73861417 -64704305 -88769927 -5594186 -14969716 22500876 62914086 5061433 89515904 67334397 -88134056 61298624 -86093694 -23119877...

output:

185968520

result:

ok 1 number(s): "185968520"

Test #97:

score: 0
Accepted
time: 35ms
memory: 35512kb

input:

100000
-31420831 43767964 -27162284 27457419 26198223 -45319078 38808915 -22394907 52895853 -36460832 95952418 -90060873 -11821134 94971138 -73465919 61961624 22279919 16178899 20614091 -22959053 12705321 -60379711 -66878992 -73473498 64416702 86864012 59272283 -12955389 35953238 38756523 41476487 -...

output:

244890788

result:

ok 1 number(s): "244890788"

Test #98:

score: 0
Accepted
time: 42ms
memory: 35468kb

input:

100000
71509485 87968050 -4787643 76711884 -59820272 -77804167 31927416 78565316 72227405 86160015 67720471 80396963 -21739903 -1425451 -91837625 -70843693 -74100625 89108488 -29168703 89895034 63429548 1925794 -17768863 -35470640 77293687 -94550706 1708499 -89017008 27981122 75426807 4995911 794809...

output:

665423671

result:

ok 1 number(s): "665423671"

Test #99:

score: 0
Accepted
time: 46ms
memory: 35512kb

input:

100000
75620818 -22640203 -36704617 -84993202 47543650 -35076414 -88441560 56471113 -76451882 91454739 38056539 -14366337 -41006767 72423280 63970089 -38212785 -58259070 5242791 -55982369 -18130667 44665876 7018779 37482372 37759179 -17952147 90233635 -87699764 -71737330 -20156612 -86568375 -8880576...

output:

883929310

result:

ok 1 number(s): "883929310"

Test #100:

score: 0
Accepted
time: 47ms
memory: 35484kb

input:

100000
92491803 -99611757 -73702093 -99871003 -9119154 52974300 91202677 -17524266 -23376658 81967113 -4360980 41357627 -47682995 86413115 67913914 52924328 -50484413 -98470715 -70499110 -59577012 -29374265 8972385 -50177319 -33498625 -63471783 -37499275 16446542 -39342445 74625266 -23578062 -675446...

output:

786511771

result:

ok 1 number(s): "786511771"

Test #101:

score: 0
Accepted
time: 35ms
memory: 35272kb

input:

100000
48432858 -30151773 -94501536 69291700 28749575 -24031371 -39525925 -26161040 93330616 23153014 -14821168 -60620538 -18037910 -92154760 -59446307 -12829528 -55635493 1853125 59965262 95804019 -2534411 64301183 -36961480 7259192 -27913087 -65186438 80272032 -65842565 70483077 -25519481 7145899 ...

output:

423300913

result:

ok 1 number(s): "423300913"

Test #102:

score: 0
Accepted
time: 41ms
memory: 35580kb

input:

100000
-32799213 -96826600 12498994 -15918959 -88038041 -37109466 -48834322 -48985013 -66504742 29831939 34164276 26603256 81319988 86745754 -86812644 -49702319 87382455 -65456462 98648167 57636864 70002886 -48706813 7178979 -88347959 82320790 41574811 -94470451 94101832 75269061 54873014 -49997088 ...

output:

805154046

result:

ok 1 number(s): "805154046"

Test #103:

score: 0
Accepted
time: 39ms
memory: 35404kb

input:

100000
68440836 -96343676 74781949 -5189801 30707662 46476423 -73362966 -30723255 75006247 95378000 2211877 -63200298 40363616 -39407718 -59354776 -48030233 59554539 -19908341 9159304 -95056288 -56160844 -49949358 -79125608 -33093034 97997155 52908187 16054862 -31891137 68333806 -39356887 -13853264 ...

output:

484455933

result:

ok 1 number(s): "484455933"

Test #104:

score: 0
Accepted
time: 42ms
memory: 35472kb

input:

100000
11956229 90769659 53706798 31089183 59593903 18614124 -30418050 -54815385 33680832 -56986093 -45025568 1194007 -16614658 -43567761 71137519 -18920497 -26281052 71347051 39777947 -35055446 -4378137 93288799 34145646 51784830 -24162258 -36504979 -73967297 -77749357 -90130196 11224149 -22690299 ...

output:

821300768

result:

ok 1 number(s): "821300768"

Test #105:

score: 0
Accepted
time: 36ms
memory: 35276kb

input:

100000
26146240 -42836480 -19972737 67636779 -91254250 -75925012 -11593964 68588679 93389682 95204564 64224286 -49890163 97213254 -37282704 -73337930 -66392463 -8293725 -71264263 -13788292 89530448 3670803 -7949889 -2810624 41223015 59272940 -13869984 18330058 -88505388 -74232929 19312148 -64823052 ...

output:

881206934

result:

ok 1 number(s): "881206934"

Test #106:

score: 0
Accepted
time: 39ms
memory: 35276kb

input:

100000
-6591288 84730336 53309221 61744586 99254296 -84877767 -78995861 38290263 39033754 35618223 11724273 -71956117 -64084371 13095289 79855131 20982321 84979246 50400467 -63275066 -85354927 18567973 -66438572 -90419897 -94948996 73026398 -46442903 -84727027 -51041422 -63358855 -79626281 -34905450...

output:

888926703

result:

ok 1 number(s): "888926703"

Test #107:

score: 0
Accepted
time: 41ms
memory: 35528kb

input:

100000
35972702 -11820331 21629353 -11286645 89944652 6780004 34855104 36684725 24391468 10296004 74072399 77289661 -20112385 -6322884 89126844 -53789760 92100246 21227330 -97715938 83300009 60634467 -6175927 81088041 -48019634 44871590 67419207 80653652 10944357 39732816 -59781877 86149310 -5369642...

output:

757617452

result:

ok 1 number(s): "757617452"

Test #108:

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

input:

100000
-39137369 34507094 54891449 3741089 -43635660 -33157562 75605132 76099858 89807988 13541487 15848714 -99309367 43026591 -83031167 95055644 99813585 29625028 -19708581 46605762 -40346497 -84500753 -85709688 -88526418 -8864871 79207541 -89666055 4981349 -89344035 -11693147 317268 71032545 -8480...

output:

19244222

result:

ok 1 number(s): "19244222"

Test #109:

score: 0
Accepted
time: 44ms
memory: 35572kb

input:

100000
88797117 34618725 -42353118 78862017 -6074649 -84578282 -92804036 34682970 48408040 -44043375 -59165258 97313940 -7517551 28567964 40101611 -14229719 -96990404 -37843592 -137299 57352377 93705099 -99039130 54732143 -14465475 -9605158 -35684740 -89435888 34077494 39987389 46990412 -10808252 39...

output:

637788353

result:

ok 1 number(s): "637788353"

Test #110:

score: 0
Accepted
time: 30ms
memory: 35516kb

input:

100000
20594977 89092463 -26956283 68239905 -45889577 -16277313 -41048317 -23509748 16450366 5711651 72456859 -47553175 94002740 -24065230 78334395 -32271923 -62539075 -23784017 52165327 82046693 16707405 -47785178 -58468847 -8722497 -42773269 34791833 2526578 -56580795 60324172 -21221006 -7605907 -...

output:

455554234

result:

ok 1 number(s): "455554234"

Test #111:

score: 0
Accepted
time: 42ms
memory: 35520kb

input:

100000
-63667471 -34034663 28562602 -66492463 -93587060 -93557984 -92948757 72348370 -67443716 23717296 54997476 12589013 38522879 89547451 -27281681 10340325 50594066 -86152802 9924003 -69265877 57912459 -91832976 55090977 12900914 51673190 3286892 3333701 -72392042 -61795734 -97974690 62027216 -51...

output:

770105322

result:

ok 1 number(s): "770105322"

Test #112:

score: 0
Accepted
time: 38ms
memory: 35356kb

input:

100000
68371518 73079712 -78920894 91006505 4880918 74229929 96811063 -41523258 6765982 -58591964 -70588849 96402227 -35680605 46768296 -31804431 37348316 -97828037 37674613 42607868 -80470586 16566550 59726936 -57959035 -81220242 -68614282 93272078 -93794549 90731518 -16360583 -39816416 36651010 -1...

output:

277902898

result:

ok 1 number(s): "277902898"

Test #113:

score: 0
Accepted
time: 20ms
memory: 33632kb

input:

100000
-100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000000 -100000...

output:

338130403

result:

ok 1 number(s): "338130403"

Test #114:

score: 0
Accepted
time: 11ms
memory: 33672kb

input:

100000
100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100000000 100...

output:

979480879

result:

ok 1 number(s): "979480879"