QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#335721 | #1169. Generate The Array | Aaronwrq | AC ✓ | 405ms | 317080kb | C++14 | 2.1kb | 2024-02-23 20:30:28 | 2024-02-23 20:30:29 |
Judging History
answer
#include <bits/stdc++.h>
#define MAXN 310
#define MAXK 300010
using namespace std;
int n, k, tot;
long long a[MAXN][MAXN], s[MAXN][MAXN], w[MAXN][MAXN][MAXN], val[MAXN][MAXN][MAXN], dp[MAXN][MAXN];
const long long inf = 0x3f3f3f3f3f3f3f3fll;
struct Point{long long x, y;};
Point b[MAXK], h[MAXK];
bool cmp(const Point a, const Point b) {return a.x == b.x ? a.y < b.y : a.x < b.x;}
Point operator-(Point a, Point b) {a.x -= b.x, a.y -= b.y; return a;}
__int128 cprod(Point a, Point b) {return (__int128)a.x * b.y - (__int128)a.y * b.x;}
long long getb(const long long k, const Point a) {return a.x * k - a.y;}
void Add(const Point a) {
while (tot > 1 && cprod(h[tot] - h[tot - 1], a - h[tot]) <= 0) --tot;
h[++tot] = a;
return;
}
long long getval(const long long k) {
int l = 1, r = tot, mid;
while (l < r) {
mid = (l + r) >> 1;
if (getb(k, h[mid]) < getb(k, h[mid + 1])) l = mid + 1;
else r = mid;
}
return getb(k, h[l]);
}
int main()
{
cin >> n;
for (int i = 1; i <= n; ++i) for (int j = i; j <= n; ++j) cin >> a[i][j];
for (int i = 1; i <= n; ++i) for (int j = 1; j <= n; ++j) s[i][j] = s[i][j - 1] + s[i - 1][j] - s[i - 1][j - 1] + a[i][j];
for (int i = 1; i <= n; ++i) for (int j = i; j <= n; ++j) for (int k = i; k <= j; ++k) w[k][i][j] = s[k][j] - s[k][k - 1] - s[i - 1][j] + s[i - 1][k - 1];
for (int i = 1; i <= n; ++i) {
cin >> k; tot = 0;
for (int j = 1; j <= k; ++j) {
long long v, c; cin >> v >> c;
b[j] = Point{v, c};
}
sort(b + 1, b + k + 1, cmp);
for (int j = 1; j <= k; ++j) Add(b[j]);
for (int l = 1; l <= i; ++l) for (int r = i; r <= n; ++r) {
val[i][l][r] = getval(w[i][l][r]);
}
}
for (int len = 1; len <= n; ++len) for (int l = 1, r = len; r <= n; ++l, ++r) {
dp[l][r] = -inf;
for (int p = l; p <= r; ++p) dp[l][r] = max(dp[l][r], dp[l][p - 1] + dp[p + 1][r] + val[p][l][r]);
}
// for (int i = 1; i <= tot; ++i) cout << h[i].x << " " << h[i].y << "\n";
// for (int i = 1; i <= n; ++i, cout << "\n") for (int l = 1; l <= i; ++l, cout << "\n") for (int r = i; r <= n; ++r) cout << val[i][l][r] << " ";
cout << dp[1][n] << "\n";
return 0;
}
详细
Test #1:
score: 100
Accepted
time: 0ms
memory: 18008kb
input:
5 1 0 2 2 0 0 2 2 0 2 2 2 1 2 0 2 0 27 1 19 2 7 25 1 1 2 8 7 4 18 2 8 7 4 4 2 0 25 4 26
output:
78
result:
ok 1 number(s): "78"
Test #2:
score: 0
Accepted
time: 2ms
memory: 13968kb
input:
2 1 1 1 2 1 100 2 50 1 1 100
output:
-145
result:
ok 1 number(s): "-145"
Test #3:
score: 0
Accepted
time: 166ms
memory: 278124kb
input:
300 791 246 453 104 979 932 79 625 573 836 378 302 70 70 5 424 656 262 799 471 107 998 874 452 227 26 435 896 816 466 372 596 212 931 459 879 265 686 216 996 553 304 547 680 540 961 931 16 549 445 512 545 781 542 930 295 247 359 927 631 978 738 409 364 443 980 286 13 576 356 462 909 821 703 489 10 5...
output:
451781489678
result:
ok 1 number(s): "451781489678"
Test #4:
score: 0
Accepted
time: 152ms
memory: 293500kb
input:
300 511 90 199 774 41 709 63 613 729 314 625 45 968 799 520 341 82 12 521 711 47 776 384 836 84 42 657 949 232 632 791 162 503 364 568 287 699 57 454 106 846 419 136 327 728 748 551 260 167 616 329 789 362 362 122 529 838 684 78 243 681 356 744 154 474 345 967 137 175 194 819 992 940 215 364 145 755...
output:
448802887313
result:
ok 1 number(s): "448802887313"
Test #5:
score: 0
Accepted
time: 125ms
memory: 293496kb
input:
300 639 743 456 955 294 974 238 305 884 201 769 789 58 40 843 258 997 275 244 656 796 65 893 707 645 250 174 810 544 310 17 137 603 500 380 887 724 836 795 513 242 637 917 781 429 832 362 96 889 570 739 841 160 990 18 467 428 305 637 47 897 165 79 728 209 710 48 261 774 328 664 74 659 727 136 575 40...
output:
450025318634
result:
ok 1 number(s): "450025318634"
Test #6:
score: 0
Accepted
time: 138ms
memory: 297664kb
input:
300 63 587 202 433 356 751 925 589 552 383 208 341 852 474 358 175 719 25 262 409 544 843 210 90 502 458 395 375 857 477 243 215 190 932 193 295 158 207 737 728 239 752 697 940 322 211 174 340 507 741 661 597 741 811 210 702 315 926 684 555 600 782 119 709 240 268 537 384 565 654 213 564 675 134 11 ...
output:
450583665163
result:
ok 1 number(s): "450583665163"
Test #7:
score: 0
Accepted
time: 135ms
memory: 296188kb
input:
300 191 728 756 614 609 528 397 281 411 861 944 380 943 715 977 796 145 287 280 354 485 621 719 769 359 179 320 428 977 347 661 782 481 69 494 896 184 282 975 134 340 970 990 394 318 999 985 584 421 696 479 136 538 439 618 640 906 547 835 167 111 887 454 283 463 633 513 508 163 788 866 647 690 646 8...
output:
450891112678
result:
ok 1 number(s): "450891112678"
Test #8:
score: 0
Accepted
time: 138ms
memory: 298848kb
input:
300 911 572 309 284 863 496 84 269 567 747 88 124 33 444 4 905 60 845 2 402 937 207 525 153 920 387 837 585 289 513 887 860 68 501 603 304 618 357 212 53 633 84 475 849 507 275 797 420 39 355 888 892 823 259 810 682 689 872 690 972 815 504 789 265 198 998 298 928 954 626 415 241 409 158 466 570 476 ...
output:
450773173363
result:
ok 1 number(s): "450773173363"
Test #9:
score: 0
Accepted
time: 155ms
memory: 297780kb
input:
300 40 416 759 466 925 273 67 553 426 930 527 164 827 685 815 822 486 596 20 347 686 688 34 832 777 595 58 150 410 384 113 835 463 637 416 904 347 920 450 460 733 495 552 7 696 62 904 664 657 821 706 944 108 784 2 917 872 493 441 480 926 121 828 543 230 852 787 755 553 760 259 27 424 670 533 704 636...
output:
451862446420
result:
ok 1 number(s): "451862446420"
Test #10:
score: 0
Accepted
time: 151ms
memory: 297356kb
input:
300 464 261 313 943 178 346 539 437 582 112 671 419 726 414 842 739 401 154 446 588 627 466 351 407 338 803 280 203 722 254 531 209 458 366 716 312 77 699 687 570 26 417 37 166 693 146 420 908 379 480 820 188 202 708 898 855 463 114 296 92 437 930 163 821 261 217 764 879 856 894 616 814 247 373 408 ...
output:
451022179903
result:
ok 1 number(s): "451022179903"
Test #11:
score: 0
Accepted
time: 131ms
memory: 296384kb
input:
300 888 913 762 125 432 315 226 425 737 294 110 459 112 656 653 656 123 608 464 341 375 348 565 790 899 228 797 64 138 124 54 479 45 502 529 912 807 70 925 785 319 532 330 812 881 933 527 448 997 947 229 240 487 232 794 90 53 439 639 896 141 843 10 906 996 878 549 299 647 220 461 896 262 885 692 564...
output:
450801726353
result:
ok 1 number(s): "450801726353"
Test #12:
score: 0
Accepted
time: 136ms
memory: 297020kb
input:
300 959 874 797 575 298 535 645 718 947 327 80 257 467 71 174 919 541 399 85 508 103 379 637 811 13 99 989 961 766 355 124 786 45 812 800 769 593 585 67 293 549 387 368 134 281 902 715 716 471 921 342 680 727 858 29 209 427 736 171 225 628 495 226 950 939 712 864 561 152 558 148 602 527 113 509 282 ...
output:
451693457699
result:
ok 1 number(s): "451693457699"
Test #13:
score: 0
Accepted
time: 144ms
memory: 296984kb
input:
300 791 246 453 104 979 932 79 625 573 836 378 302 70 70 5 424 656 262 799 471 107 998 874 452 227 26 435 896 816 466 372 596 212 931 459 879 265 686 216 996 553 304 547 680 540 961 931 16 549 445 512 545 781 542 930 295 247 359 927 631 978 738 409 364 443 980 286 13 576 356 462 909 821 703 489 10 5...
output:
451118727187
result:
ok 1 number(s): "451118727187"
Test #14:
score: 0
Accepted
time: 144ms
memory: 297716kb
input:
300 511 90 199 774 41 709 63 613 729 314 625 45 968 799 520 341 82 12 521 711 47 776 384 836 84 42 657 949 232 632 791 162 503 364 568 287 699 57 454 106 846 419 136 327 728 748 551 260 167 616 329 789 362 362 122 529 838 684 78 243 681 356 744 154 474 345 967 137 175 194 819 992 940 215 364 145 755...
output:
448135681077
result:
ok 1 number(s): "448135681077"
Test #15:
score: 0
Accepted
time: 140ms
memory: 296892kb
input:
300 639 743 456 955 294 974 238 305 884 201 769 789 58 40 843 258 997 275 244 656 796 65 893 707 645 250 174 810 544 310 17 137 603 500 380 887 724 836 795 513 242 637 917 781 429 832 362 96 889 570 739 841 160 990 18 467 428 305 637 47 897 165 79 728 209 710 48 261 774 328 664 74 659 727 136 575 40...
output:
449362743284
result:
ok 1 number(s): "449362743284"
Test #16:
score: 0
Accepted
time: 139ms
memory: 297516kb
input:
300 63 587 202 433 356 751 925 589 552 383 208 341 852 474 358 175 719 25 262 409 544 843 210 90 502 458 395 375 857 477 243 215 190 932 193 295 158 207 737 728 239 752 697 940 322 211 174 340 507 741 661 597 741 811 210 702 315 926 684 555 600 782 119 709 240 268 537 384 565 654 213 564 675 134 11 ...
output:
449892590405
result:
ok 1 number(s): "449892590405"
Test #17:
score: 0
Accepted
time: 135ms
memory: 297504kb
input:
300 191 728 756 614 609 528 397 281 411 861 944 380 943 715 977 796 145 287 280 354 485 621 719 769 359 179 320 428 977 347 661 782 481 69 494 896 184 282 975 134 340 970 990 394 318 999 985 584 421 696 479 136 538 439 618 640 906 547 835 167 111 887 454 283 463 633 513 508 163 788 866 647 690 646 8...
output:
450222744293
result:
ok 1 number(s): "450222744293"
Test #18:
score: 0
Accepted
time: 144ms
memory: 297512kb
input:
300 911 572 309 284 863 496 84 269 567 747 88 124 33 444 4 905 60 845 2 402 937 207 525 153 920 387 837 585 289 513 887 860 68 501 603 304 618 357 212 53 633 84 475 849 507 275 797 420 39 355 888 892 823 259 810 682 689 872 690 972 815 504 789 265 198 998 298 928 954 626 415 241 409 158 466 570 476 ...
output:
450090999665
result:
ok 1 number(s): "450090999665"
Test #19:
score: 0
Accepted
time: 140ms
memory: 297488kb
input:
300 40 416 759 466 925 273 67 553 426 930 527 164 827 685 815 822 486 596 20 347 686 688 34 832 777 595 58 150 410 384 113 835 463 637 416 904 347 920 450 460 733 495 552 7 696 62 904 664 657 821 706 944 108 784 2 917 872 493 441 480 926 121 828 543 230 852 787 755 553 760 259 27 424 670 533 704 636...
output:
451201756518
result:
ok 1 number(s): "451201756518"
Test #20:
score: 0
Accepted
time: 144ms
memory: 297112kb
input:
300 464 261 313 943 178 346 539 437 582 112 671 419 726 414 842 739 401 154 446 588 627 466 351 407 338 803 280 203 722 254 531 209 458 366 716 312 77 699 687 570 26 417 37 166 693 146 420 908 379 480 820 188 202 708 898 855 463 114 296 92 437 930 163 821 261 217 764 879 856 894 616 814 247 373 408 ...
output:
450331334287
result:
ok 1 number(s): "450331334287"
Test #21:
score: 0
Accepted
time: 142ms
memory: 296140kb
input:
300 888 913 762 125 432 315 226 425 737 294 110 459 112 656 653 656 123 608 464 341 375 348 565 790 899 228 797 64 138 124 54 479 45 502 529 912 807 70 925 785 319 532 330 812 881 933 527 448 997 947 229 240 487 232 794 90 53 439 639 896 141 843 10 906 996 878 549 299 647 220 461 896 262 885 692 564...
output:
450132895974
result:
ok 1 number(s): "450132895974"
Test #22:
score: 0
Accepted
time: 140ms
memory: 298972kb
input:
300 959 874 797 575 298 535 645 718 947 327 80 257 467 71 174 919 541 399 85 508 103 379 637 811 13 99 989 961 766 355 124 786 45 812 800 769 593 585 67 293 549 387 368 134 281 902 715 716 471 921 342 680 727 858 29 209 427 736 171 225 628 495 226 950 939 712 864 561 152 558 148 602 527 113 509 282 ...
output:
451032042761
result:
ok 1 number(s): "451032042761"
Test #23:
score: 0
Accepted
time: 165ms
memory: 297440kb
input:
300 791 246 453 104 979 932 79 625 573 836 378 302 70 70 5 424 656 262 799 471 107 998 874 452 227 26 435 896 816 466 372 596 212 931 459 879 265 686 216 996 553 304 547 680 540 961 931 16 549 445 512 545 781 542 930 295 247 359 927 631 978 738 409 364 443 980 286 13 576 356 462 909 821 703 489 10 5...
output:
2221033350629661
result:
ok 1 number(s): "2221033350629661"
Test #24:
score: 0
Accepted
time: 179ms
memory: 297444kb
input:
300 511 90 199 774 41 709 63 613 729 314 625 45 968 799 520 341 82 12 521 711 47 776 384 836 84 42 657 949 232 632 791 162 503 364 568 287 699 57 454 106 846 419 136 327 728 748 551 260 167 616 329 789 362 362 122 529 838 684 78 243 681 356 744 154 474 345 967 137 175 194 819 992 940 215 364 145 755...
output:
2199939844756666
result:
ok 1 number(s): "2199939844756666"
Test #25:
score: 0
Accepted
time: 173ms
memory: 297216kb
input:
300 639 743 456 955 294 974 238 305 884 201 769 789 58 40 843 258 997 275 244 656 796 65 893 707 645 250 174 810 544 310 17 137 603 500 380 887 724 836 795 513 242 637 917 781 429 832 362 96 889 570 739 841 160 990 18 467 428 305 637 47 897 165 79 728 209 710 48 261 774 328 664 74 659 727 136 575 40...
output:
2205967670291014
result:
ok 1 number(s): "2205967670291014"
Test #26:
score: 0
Accepted
time: 178ms
memory: 297160kb
input:
300 63 587 202 433 356 751 925 589 552 383 208 341 852 474 358 175 719 25 262 409 544 843 210 90 502 458 395 375 857 477 243 215 190 932 193 295 158 207 737 728 239 752 697 940 322 211 174 340 507 741 661 597 741 811 210 702 315 926 684 555 600 782 119 709 240 268 537 384 565 654 213 564 675 134 11 ...
output:
2219364185853780
result:
ok 1 number(s): "2219364185853780"
Test #27:
score: 0
Accepted
time: 156ms
memory: 296236kb
input:
300 191 728 756 614 609 528 397 281 411 861 944 380 943 715 977 796 145 287 280 354 485 621 719 769 359 179 320 428 977 347 661 782 481 69 494 896 184 282 975 134 340 970 990 394 318 999 985 584 421 696 479 136 538 439 618 640 906 547 835 167 111 887 454 283 463 633 513 508 163 788 866 647 690 646 8...
output:
2222267464242326
result:
ok 1 number(s): "2222267464242326"
Test #28:
score: 0
Accepted
time: 192ms
memory: 298788kb
input:
300 911 572 309 284 863 496 84 269 567 747 88 124 33 444 4 905 60 845 2 402 937 207 525 153 920 387 837 585 289 513 887 860 68 501 603 304 618 357 212 53 633 84 475 849 507 275 797 420 39 355 888 892 823 259 810 682 689 872 690 972 815 504 789 265 198 998 298 928 954 626 415 241 409 158 466 570 476 ...
output:
2221934391466006
result:
ok 1 number(s): "2221934391466006"
Test #29:
score: 0
Accepted
time: 164ms
memory: 297376kb
input:
300 40 416 759 466 925 273 67 553 426 930 527 164 827 685 815 822 486 596 20 347 686 688 34 832 777 595 58 150 410 384 113 835 463 637 416 904 347 920 450 460 733 495 552 7 696 62 904 664 657 821 706 944 108 784 2 917 872 493 441 480 926 121 828 543 230 852 787 755 553 760 259 27 424 670 533 704 636...
output:
2229454562031250
result:
ok 1 number(s): "2229454562031250"
Test #30:
score: 0
Accepted
time: 183ms
memory: 297516kb
input:
300 464 261 313 943 178 346 539 437 582 112 671 419 726 414 842 739 401 154 446 588 627 466 351 407 338 803 280 203 722 254 531 209 458 366 716 312 77 699 687 570 26 417 37 166 693 146 420 908 379 480 820 188 202 708 898 855 463 114 296 92 437 930 163 821 261 217 764 879 856 894 616 814 247 373 408 ...
output:
2216168104948424
result:
ok 1 number(s): "2216168104948424"
Test #31:
score: 0
Accepted
time: 163ms
memory: 298564kb
input:
300 888 913 762 125 432 315 226 425 737 294 110 459 112 656 653 656 123 608 464 341 375 348 565 790 899 228 797 64 138 124 54 479 45 502 529 912 807 70 925 785 319 532 330 812 881 933 527 448 997 947 229 240 487 232 794 90 53 439 639 896 141 843 10 906 996 878 549 299 647 220 461 896 262 885 692 564...
output:
2219576030815369
result:
ok 1 number(s): "2219576030815369"
Test #32:
score: 0
Accepted
time: 188ms
memory: 297452kb
input:
300 959 874 797 575 298 535 645 718 947 327 80 257 467 71 174 919 541 399 85 508 103 379 637 811 13 99 989 961 766 355 124 786 45 812 800 769 593 585 67 293 549 387 368 134 281 902 715 716 471 921 342 680 727 858 29 209 427 736 171 225 628 495 226 950 939 712 864 561 152 558 148 602 527 113 509 282 ...
output:
2227129713105530
result:
ok 1 number(s): "2227129713105530"
Test #33:
score: 0
Accepted
time: 137ms
memory: 297728kb
input:
300 791 246 453 104 979 932 79 625 573 836 378 302 70 70 5 424 656 262 799 471 107 998 874 452 227 26 435 896 816 466 372 596 212 931 459 879 265 686 216 996 553 304 547 680 540 961 931 16 549 445 512 545 781 542 930 295 247 359 927 631 978 738 409 364 443 980 286 13 576 356 462 909 821 703 489 10 5...
output:
1973719498535804
result:
ok 1 number(s): "1973719498535804"
Test #34:
score: 0
Accepted
time: 143ms
memory: 297136kb
input:
300 511 90 199 774 41 709 63 613 729 314 625 45 968 799 520 341 82 12 521 711 47 776 384 836 84 42 657 949 232 632 791 162 503 364 568 287 699 57 454 106 846 419 136 327 728 748 551 260 167 616 329 789 362 362 122 529 838 684 78 243 681 356 744 154 474 345 967 137 175 194 819 992 940 215 364 145 755...
output:
1962947760074476
result:
ok 1 number(s): "1962947760074476"
Test #35:
score: 0
Accepted
time: 155ms
memory: 297516kb
input:
300 639 743 456 955 294 974 238 305 884 201 769 789 58 40 843 258 997 275 244 656 796 65 893 707 645 250 174 810 544 310 17 137 603 500 380 887 724 836 795 513 242 637 917 781 429 832 362 96 889 570 739 841 160 990 18 467 428 305 637 47 897 165 79 728 209 710 48 261 774 328 664 74 659 727 136 575 40...
output:
1958455328454424
result:
ok 1 number(s): "1958455328454424"
Test #36:
score: 0
Accepted
time: 173ms
memory: 296536kb
input:
300 63 587 202 433 356 751 925 589 552 383 208 341 852 474 358 175 719 25 262 409 544 843 210 90 502 458 395 375 857 477 243 215 190 932 193 295 158 207 737 728 239 752 697 940 322 211 174 340 507 741 661 597 741 811 210 702 315 926 684 555 600 782 119 709 240 268 537 384 565 654 213 564 675 134 11 ...
output:
1966425134752992
result:
ok 1 number(s): "1966425134752992"
Test #37:
score: 0
Accepted
time: 160ms
memory: 298404kb
input:
300 191 728 756 614 609 528 397 281 411 861 944 380 943 715 977 796 145 287 280 354 485 621 719 769 359 179 320 428 977 347 661 782 481 69 494 896 184 282 975 134 340 970 990 394 318 999 985 584 421 696 479 136 538 439 618 640 906 547 835 167 111 887 454 283 463 633 513 508 163 788 866 647 690 646 8...
output:
1968597597953728
result:
ok 1 number(s): "1968597597953728"
Test #38:
score: 0
Accepted
time: 180ms
memory: 297724kb
input:
300 911 572 309 284 863 496 84 269 567 747 88 124 33 444 4 905 60 845 2 402 937 207 525 153 920 387 837 585 289 513 887 860 68 501 603 304 618 357 212 53 633 84 475 849 507 275 797 420 39 355 888 892 823 259 810 682 689 872 690 972 815 504 789 265 198 998 298 928 954 626 415 241 409 158 466 570 476 ...
output:
1967506252474583
result:
ok 1 number(s): "1967506252474583"
Test #39:
score: 0
Accepted
time: 171ms
memory: 297004kb
input:
300 40 416 759 466 925 273 67 553 426 930 527 164 827 685 815 822 486 596 20 347 686 688 34 832 777 595 58 150 410 384 113 835 463 637 416 904 347 920 450 460 733 495 552 7 696 62 904 664 657 821 706 944 108 784 2 917 872 493 441 480 926 121 828 543 230 852 787 755 553 760 259 27 424 670 533 704 636...
output:
1975897251239036
result:
ok 1 number(s): "1975897251239036"
Test #40:
score: 0
Accepted
time: 153ms
memory: 297172kb
input:
300 464 261 313 943 178 346 539 437 582 112 671 419 726 414 842 739 401 154 446 588 627 466 351 407 338 803 280 203 722 254 531 209 458 366 716 312 77 699 687 570 26 417 37 166 693 146 420 908 379 480 820 188 202 708 898 855 463 114 296 92 437 930 163 821 261 217 764 879 856 894 616 814 247 373 408 ...
output:
1972452710431520
result:
ok 1 number(s): "1972452710431520"
Test #41:
score: 0
Accepted
time: 173ms
memory: 297444kb
input:
300 888 913 762 125 432 315 226 425 737 294 110 459 112 656 653 656 123 608 464 341 375 348 565 790 899 228 797 64 138 124 54 479 45 502 529 912 807 70 925 785 319 532 330 812 881 933 527 448 997 947 229 240 487 232 794 90 53 439 639 896 141 843 10 906 996 878 549 299 647 220 461 896 262 885 692 564...
output:
1959764610950880
result:
ok 1 number(s): "1959764610950880"
Test #42:
score: 0
Accepted
time: 179ms
memory: 297496kb
input:
300 959 874 797 575 298 535 645 718 947 327 80 257 467 71 174 919 541 399 85 508 103 379 637 811 13 99 989 961 766 355 124 786 45 812 800 769 593 585 67 293 549 387 368 134 281 902 715 716 471 921 342 680 727 858 29 209 427 736 171 225 628 495 226 950 939 712 864 561 152 558 148 602 527 113 509 282 ...
output:
1975844637722030
result:
ok 1 number(s): "1975844637722030"
Test #43:
score: 0
Accepted
time: 63ms
memory: 297520kb
input:
300 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 ...
output:
-3000000000000000
result:
ok 1 number(s): "-3000000000000000"
Test #44:
score: 0
Accepted
time: 63ms
memory: 297064kb
input:
300 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 ...
output:
1510485000000000
result:
ok 1 number(s): "1510485000000000"
Test #45:
score: 0
Accepted
time: 64ms
memory: 297052kb
input:
300 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 ...
output:
4510485000000000
result:
ok 1 number(s): "4510485000000000"
Test #46:
score: 0
Accepted
time: 47ms
memory: 296940kb
input:
300 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 999 ...
output:
0
result:
ok 1 number(s): "0"
Test #47:
score: 0
Accepted
time: 269ms
memory: 297488kb
input:
300 791 246 453 104 979 932 79 625 573 836 378 302 70 70 5 424 656 262 799 471 107 998 874 452 227 26 435 896 816 466 372 596 212 931 459 879 265 686 216 996 553 304 547 680 540 961 931 16 549 445 512 545 781 542 930 295 247 359 927 631 978 738 409 364 443 980 286 13 576 356 462 909 821 703 489 10 5...
output:
46987654208157
result:
ok 1 number(s): "46987654208157"
Test #48:
score: 0
Accepted
time: 312ms
memory: 297212kb
input:
300 511 90 199 774 41 709 63 613 729 314 625 45 968 799 520 341 82 12 521 711 47 776 384 836 84 42 657 949 232 632 791 162 503 364 568 287 699 57 454 106 846 419 136 327 728 748 551 260 167 616 329 789 362 362 122 529 838 684 78 243 681 356 744 154 474 345 967 137 175 194 819 992 940 215 364 145 755...
output:
46842870136142
result:
ok 1 number(s): "46842870136142"
Test #49:
score: 0
Accepted
time: 277ms
memory: 297596kb
input:
300 639 743 456 955 294 974 238 305 884 201 769 789 58 40 843 258 997 275 244 656 796 65 893 707 645 250 174 810 544 310 17 137 603 500 380 887 724 836 795 513 242 637 917 781 429 832 362 96 889 570 739 841 160 990 18 467 428 305 637 47 897 165 79 728 209 710 48 261 774 328 664 74 659 727 136 575 40...
output:
46789189459107
result:
ok 1 number(s): "46789189459107"
Test #50:
score: 0
Accepted
time: 280ms
memory: 297580kb
input:
300 63 587 202 433 356 751 925 589 552 383 208 341 852 474 358 175 719 25 262 409 544 843 210 90 502 458 395 375 857 477 243 215 190 932 193 295 158 207 737 728 239 752 697 940 322 211 174 340 507 741 661 597 741 811 210 702 315 926 684 555 600 782 119 709 240 268 537 384 565 654 213 564 675 134 11 ...
output:
46536082103454
result:
ok 1 number(s): "46536082103454"
Test #51:
score: 0
Accepted
time: 281ms
memory: 297396kb
input:
300 191 728 756 614 609 528 397 281 411 861 944 380 943 715 977 796 145 287 280 354 485 621 719 769 359 179 320 428 977 347 661 782 481 69 494 896 184 282 975 134 340 970 990 394 318 999 985 584 421 696 479 136 538 439 618 640 906 547 835 167 111 887 454 283 463 633 513 508 163 788 866 647 690 646 8...
output:
46489901000368
result:
ok 1 number(s): "46489901000368"
Test #52:
score: 0
Accepted
time: 292ms
memory: 297796kb
input:
300 911 572 309 284 863 496 84 269 567 747 88 124 33 444 4 905 60 845 2 402 937 207 525 153 920 387 837 585 289 513 887 860 68 501 603 304 618 357 212 53 633 84 475 849 507 275 797 420 39 355 888 892 823 259 810 682 689 872 690 972 815 504 789 265 198 998 298 928 954 626 415 241 409 158 466 570 476 ...
output:
46550379366074
result:
ok 1 number(s): "46550379366074"
Test #53:
score: 0
Accepted
time: 289ms
memory: 296844kb
input:
300 40 416 759 466 925 273 67 553 426 930 527 164 827 685 815 822 486 596 20 347 686 688 34 832 777 595 58 150 410 384 113 835 463 637 416 904 347 920 450 460 733 495 552 7 696 62 904 664 657 821 706 944 108 784 2 917 872 493 441 480 926 121 828 543 230 852 787 755 553 760 259 27 424 670 533 704 636...
output:
46708129820801
result:
ok 1 number(s): "46708129820801"
Test #54:
score: 0
Accepted
time: 291ms
memory: 297396kb
input:
300 464 261 313 943 178 346 539 437 582 112 671 419 726 414 842 739 401 154 446 588 627 466 351 407 338 803 280 203 722 254 531 209 458 366 716 312 77 699 687 570 26 417 37 166 693 146 420 908 379 480 820 188 202 708 898 855 463 114 296 92 437 930 163 821 261 217 764 879 856 894 616 814 247 373 408 ...
output:
47107239339937
result:
ok 1 number(s): "47107239339937"
Test #55:
score: 0
Accepted
time: 295ms
memory: 298200kb
input:
300 888 913 762 125 432 315 226 425 737 294 110 459 112 656 653 656 123 608 464 341 375 348 565 790 899 228 797 64 138 124 54 479 45 502 529 912 807 70 925 785 319 532 330 812 881 933 527 448 997 947 229 240 487 232 794 90 53 439 639 896 141 843 10 906 996 878 549 299 647 220 461 896 262 885 692 564...
output:
47046193459131
result:
ok 1 number(s): "47046193459131"
Test #56:
score: 0
Accepted
time: 321ms
memory: 297664kb
input:
300 959 874 797 575 298 535 645 718 947 327 80 257 467 71 174 919 541 399 85 508 103 379 637 811 13 99 989 961 766 355 124 786 45 812 800 769 593 585 67 293 549 387 368 134 281 902 715 716 471 921 342 680 727 858 29 209 427 736 171 225 628 495 226 950 939 712 864 561 152 558 148 602 527 113 509 282 ...
output:
46860048022072
result:
ok 1 number(s): "46860048022072"
Test #57:
score: 0
Accepted
time: 206ms
memory: 296840kb
input:
300 398 895 529 670 356 462 408 225 67 951 605 548 827 642 898 761 471 878 861 944 711 57 375 235 47 377 615 80 238 310 93 194 392 741 271 536 181 479 655 77 159 159 98 574 280 32 962 207 426 541 662 358 708 511 677 135 836 523 519 926 104 153 852 944 979 974 234 226 207 235 211 472 981 787 340 0 55...
output:
450546820190
result:
ok 1 number(s): "450546820190"
Test #58:
score: 0
Accepted
time: 190ms
memory: 298764kb
input:
300 398 895 529 670 356 462 408 225 67 951 605 548 827 642 898 761 471 878 861 944 711 57 375 235 47 377 615 80 238 310 93 194 392 741 271 536 181 479 655 77 159 159 98 574 280 32 962 207 426 541 662 358 708 511 677 135 836 523 519 926 104 153 852 944 979 974 234 226 207 235 211 472 981 787 340 0 55...
output:
449861842132
result:
ok 1 number(s): "449861842132"
Test #59:
score: 0
Accepted
time: 270ms
memory: 298204kb
input:
300 37 872 692 429 27 642 597 623 854 480 152 577 196 321 644 845 727 319 621 176 589 402 747 905 399 899 82 725 82 417 697 478 745 799 963 623 456 916 504 386 907 385 573 274 157 311 136 161 738 47 373 979 149 639 932 433 562 148 856 880 862 146 97 135 857 926 675 220 635 901 661 520 973 642 91 870...
output:
2214609776965613
result:
ok 1 number(s): "2214609776965613"
Test #60:
score: 0
Accepted
time: 274ms
memory: 298184kb
input:
300 511 461 206 465 654 689 747 465 119 425 295 643 557 392 268 127 512 430 757 492 882 870 942 778 585 625 758 777 497 250 420 967 375 713 991 807 206 776 541 540 142 768 821 74 704 845 669 358 587 718 532 161 787 750 169 928 500 982 794 463 795 256 294 729 182 397 668 186 511 609 449 942 740 306 9...
output:
2208503501961187
result:
ok 1 number(s): "2208503501961187"
Test #61:
score: 0
Accepted
time: 241ms
memory: 298924kb
input:
300 101 55 101 968 758 253 538 933 521 219 895 50 869 876 607 568 190 139 64 888 461 203 123 659 21 823 280 763 463 907 632 615 631 104 65 371 188 732 926 21 92 704 844 594 846 616 159 175 750 727 291 552 876 336 706 500 733 806 309 550 609 685 187 838 91 638 811 614 420 831 200 318 201 729 928 785 ...
output:
708928325606223
result:
ok 1 number(s): "708928325606223"
Test #62:
score: 0
Accepted
time: 249ms
memory: 299864kb
input:
300 268 252 225 716 978 14 567 149 441 609 301 533 55 320 505 646 589 824 632 34 199 348 351 732 576 482 586 357 899 372 120 536 819 40 508 701 4 688 374 146 655 779 520 341 562 898 682 691 46 236 463 437 423 362 686 790 272 187 105 46 268 314 81 554 158 803 888 641 834 401 693 952 442 43 692 87 866...
output:
783022984645826
result:
ok 1 number(s): "783022984645826"
Test #63:
score: 0
Accepted
time: 261ms
memory: 297636kb
input:
300 398 895 529 670 356 462 408 225 67 951 605 548 827 642 898 761 471 878 861 944 711 57 375 235 47 377 615 80 238 310 93 194 392 741 271 536 181 479 655 77 159 159 98 574 280 32 962 207 426 541 662 358 708 511 677 135 836 523 519 926 104 153 852 944 979 974 234 226 207 235 211 472 981 787 340 0 55...
output:
2231147292368501
result:
ok 1 number(s): "2231147292368501"
Test #64:
score: 0
Accepted
time: 267ms
memory: 298440kb
input:
300 37 872 692 429 27 642 597 623 854 480 152 577 196 321 644 845 727 319 621 176 589 402 747 905 399 899 82 725 82 417 697 478 745 799 963 623 456 916 504 386 907 385 573 274 157 311 136 161 738 47 373 979 149 639 932 433 562 148 856 880 862 146 97 135 857 926 675 220 635 901 661 520 973 642 91 870...
output:
1958387209608849
result:
ok 1 number(s): "1958387209608849"
Test #65:
score: 0
Accepted
time: 256ms
memory: 297232kb
input:
300 511 461 206 465 654 689 747 465 119 425 295 643 557 392 268 127 512 430 757 492 882 870 942 778 585 625 758 777 497 250 420 967 375 713 991 807 206 776 541 540 142 768 821 74 704 845 669 358 587 718 532 161 787 750 169 928 500 982 794 463 795 256 294 729 182 397 668 186 511 609 449 942 740 306 9...
output:
1959021743818663
result:
ok 1 number(s): "1959021743818663"
Test #66:
score: 0
Accepted
time: 232ms
memory: 298828kb
input:
300 101 55 101 968 758 253 538 933 521 219 895 50 869 876 607 568 190 139 64 888 461 203 123 659 21 823 280 763 463 907 632 615 631 104 65 371 188 732 926 21 92 704 844 594 846 616 159 175 750 727 291 552 876 336 706 500 733 806 309 550 609 685 187 838 91 638 811 614 420 831 200 318 201 729 928 785 ...
output:
699739109006711
result:
ok 1 number(s): "699739109006711"
Test #67:
score: 0
Accepted
time: 234ms
memory: 300956kb
input:
300 268 252 225 716 978 14 567 149 441 609 301 533 55 320 505 646 589 824 632 34 199 348 351 732 576 482 586 357 899 372 120 536 819 40 508 701 4 688 374 146 655 779 520 341 562 898 682 691 46 236 463 437 423 362 686 790 272 187 105 46 268 314 81 554 158 803 888 641 834 401 693 952 442 43 692 87 866...
output:
768815375120311
result:
ok 1 number(s): "768815375120311"
Test #68:
score: 0
Accepted
time: 248ms
memory: 297696kb
input:
300 398 895 529 670 356 462 408 225 67 951 605 548 827 642 898 761 471 878 861 944 711 57 375 235 47 377 615 80 238 310 93 194 392 741 271 536 181 479 655 77 159 159 98 574 280 32 962 207 426 541 662 358 708 511 677 135 836 523 519 926 104 153 852 944 979 974 234 226 207 235 211 472 981 787 340 0 55...
output:
1966751676370724
result:
ok 1 number(s): "1966751676370724"
Test #69:
score: 0
Accepted
time: 367ms
memory: 299008kb
input:
300 37 872 692 429 27 642 597 623 854 480 152 577 196 321 644 845 727 319 621 176 589 402 747 905 399 899 82 725 82 417 697 478 745 799 963 623 456 916 504 386 907 385 573 274 157 311 136 161 738 47 373 979 149 639 932 433 562 148 856 880 862 146 97 135 857 926 675 220 635 901 661 520 973 642 91 870...
output:
46920752760239
result:
ok 1 number(s): "46920752760239"
Test #70:
score: 0
Accepted
time: 353ms
memory: 298656kb
input:
300 511 461 206 465 654 689 747 465 119 425 295 643 557 392 268 127 512 430 757 492 882 870 942 778 585 625 758 777 497 250 420 967 375 713 991 807 206 776 541 540 142 768 821 74 704 845 669 358 587 718 532 161 787 750 169 928 500 982 794 463 795 256 294 729 182 397 668 186 511 609 449 942 740 306 9...
output:
47060085187253
result:
ok 1 number(s): "47060085187253"
Test #71:
score: 0
Accepted
time: 240ms
memory: 300448kb
input:
300 101 55 101 968 758 253 538 933 521 219 895 50 869 876 607 568 190 139 64 888 461 203 123 659 21 823 280 763 463 907 632 615 631 104 65 371 188 732 926 21 92 704 844 594 846 616 159 175 750 727 291 552 876 336 706 500 733 806 309 550 609 685 187 838 91 638 811 614 420 831 200 318 201 729 928 785 ...
output:
-649257984853518
result:
ok 1 number(s): "-649257984853518"
Test #72:
score: 0
Accepted
time: 236ms
memory: 302308kb
input:
300 268 252 225 716 978 14 567 149 441 609 301 533 55 320 505 646 589 824 632 34 199 348 351 732 576 482 586 357 899 372 120 536 819 40 508 701 4 688 374 146 655 779 520 341 562 898 682 691 46 236 463 437 423 362 686 790 272 187 105 46 268 314 81 554 158 803 888 641 834 401 693 952 442 43 692 87 866...
output:
-820004421391554
result:
ok 1 number(s): "-820004421391554"
Test #73:
score: 0
Accepted
time: 380ms
memory: 297736kb
input:
300 398 895 529 670 356 462 408 225 67 951 605 548 827 642 898 761 471 878 861 944 711 57 375 235 47 377 615 80 238 310 93 194 392 741 271 536 181 479 655 77 159 159 98 574 280 32 962 207 426 541 662 358 708 511 677 135 836 523 519 926 104 153 852 944 979 974 234 226 207 235 211 472 981 787 340 0 55...
output:
47202903108106
result:
ok 1 number(s): "47202903108106"
Test #74:
score: 0
Accepted
time: 208ms
memory: 296540kb
input:
300 118 739 83 147 609 239 583 405 926 133 748 99 917 76 221 678 193 924 583 993 652 642 885 914 904 393 836 941 358 180 319 273 683 173 84 432 910 553 596 187 964 378 687 29 276 308 478 451 44 8 479 602 802 35 573 177 427 144 374 434 511 770 891 518 11 531 19 54 806 73 56 66 996 299 216 430 910 888...
output:
449431616858
result:
ok 1 number(s): "449431616858"
Test #75:
score: 0
Accepted
time: 194ms
memory: 299052kb
input:
300 118 739 83 147 609 239 583 405 926 133 748 99 917 76 221 678 193 924 583 993 652 642 885 914 904 393 836 941 358 180 319 273 683 173 84 432 910 553 596 187 964 378 687 29 276 308 478 451 44 8 479 602 802 35 573 177 427 144 374 434 511 770 891 518 11 531 19 54 806 73 56 66 996 299 216 430 910 888...
output:
448728104128
result:
ok 1 number(s): "448728104128"
Test #76:
score: 0
Accepted
time: 275ms
memory: 298520kb
input:
300 461 12 142 907 88 715 580 611 713 662 591 617 287 858 967 762 346 774 343 416 338 476 257 288 256 107 303 290 394 583 923 748 844 231 72 223 186 287 742 496 200 500 58 433 346 394 947 701 652 1 487 519 946 460 828 668 345 769 903 492 373 763 432 413 889 483 460 344 426 931 210 10 284 50 967 301 ...
output:
2213547045561240
result:
ok 1 number(s): "2213547045561240"
Test #77:
score: 0
Accepted
time: 275ms
memory: 298028kb
input:
300 639 305 951 943 715 466 627 157 274 903 734 491 648 121 783 940 235 884 775 733 631 752 555 457 442 346 979 126 809 121 646 342 666 145 804 215 232 339 778 243 435 179 114 529 701 825 184 898 205 377 350 508 776 275 361 163 387 603 649 971 498 66 333 7 213 763 453 605 301 743 102 240 756 817 58 ...
output:
2208636787438525
result:
ok 1 number(s): "2208636787438525"
Test #78:
score: 0
Accepted
time: 253ms
memory: 299624kb
input:
300 525 899 655 149 12 518 225 625 677 401 631 90 959 414 930 677 913 697 786 129 913 981 633 338 582 839 501 816 583 777 858 590 730 241 174 675 918 103 460 132 681 818 433 48 842 404 266 11 664 385 916 603 161 965 899 734 324 131 164 162 312 6 226 412 18 196 596 738 19 965 557 809 216 241 700 215 ...
output:
662155733065021
result:
ok 1 number(s): "662155733065021"
Test #79:
score: 0
Accepted
time: 252ms
memory: 299988kb
input:
300 396 96 779 193 39 86 551 841 405 495 741 572 954 753 124 267 15 574 650 787 948 422 668 115 433 498 103 217 20 50 538 614 214 472 321 109 734 763 612 64 948 701 301 795 263 278 198 527 664 894 577 489 709 182 878 832 159 808 960 850 676 419 120 935 893 464 377 61 433 239 50 843 457 851 759 814 5...
output:
625888837897955
result:
ok 1 number(s): "625888837897955"
Test #80:
score: 0
Accepted
time: 250ms
memory: 297760kb
input:
300 118 739 83 147 609 239 583 405 926 133 748 99 917 76 221 678 193 924 583 993 652 642 885 914 904 393 836 941 358 180 319 273 683 173 84 432 910 553 596 187 964 378 687 29 276 308 478 451 44 8 479 602 802 35 573 177 427 144 374 434 511 770 891 518 11 531 19 54 806 73 56 66 996 299 216 430 910 888...
output:
2224551121243872
result:
ok 1 number(s): "2224551121243872"
Test #81:
score: 0
Accepted
time: 256ms
memory: 298212kb
input:
300 461 12 142 907 88 715 580 611 713 662 591 617 287 858 967 762 346 774 343 416 338 476 257 288 256 107 303 290 394 583 923 748 844 231 72 223 186 287 742 496 200 500 58 433 346 394 947 701 652 1 487 519 946 460 828 668 345 769 903 492 373 763 432 413 889 483 460 344 426 931 210 10 284 50 967 301 ...
output:
1958331179137774
result:
ok 1 number(s): "1958331179137774"
Test #82:
score: 0
Accepted
time: 254ms
memory: 297740kb
input:
300 639 305 951 943 715 466 627 157 274 903 734 491 648 121 783 940 235 884 775 733 631 752 555 457 442 346 979 126 809 121 646 342 666 145 804 215 232 339 778 243 435 179 114 529 701 825 184 898 205 377 350 508 776 275 361 163 387 603 649 971 498 66 333 7 213 763 453 605 301 743 102 240 756 817 58 ...
output:
1957585540034295
result:
ok 1 number(s): "1957585540034295"
Test #83:
score: 0
Accepted
time: 225ms
memory: 300104kb
input:
300 525 899 655 149 12 518 225 625 677 401 631 90 959 414 930 677 913 697 786 129 913 981 633 338 582 839 501 816 583 777 858 590 730 241 174 675 918 103 460 132 681 818 433 48 842 404 266 11 664 385 916 603 161 965 899 734 324 131 164 162 312 6 226 412 18 196 596 738 19 965 557 809 216 241 700 215 ...
output:
651764560859200
result:
ok 1 number(s): "651764560859200"
Test #84:
score: 0
Accepted
time: 244ms
memory: 299704kb
input:
300 396 96 779 193 39 86 551 841 405 495 741 572 954 753 124 267 15 574 650 787 948 422 668 115 433 498 103 217 20 50 538 614 214 472 321 109 734 763 612 64 948 701 301 795 263 278 198 527 664 894 577 489 709 182 878 832 159 808 960 850 676 419 120 935 893 464 377 61 433 239 50 843 457 851 759 814 5...
output:
612614101832425
result:
ok 1 number(s): "612614101832425"
Test #85:
score: 0
Accepted
time: 259ms
memory: 297584kb
input:
300 118 739 83 147 609 239 583 405 926 133 748 99 917 76 221 678 193 924 583 993 652 642 885 914 904 393 836 941 358 180 319 273 683 173 84 432 910 553 596 187 964 378 687 29 276 308 478 451 44 8 479 602 802 35 573 177 427 144 374 434 511 770 891 518 11 531 19 54 806 73 56 66 996 299 216 430 910 888...
output:
1962657383239525
result:
ok 1 number(s): "1962657383239525"
Test #86:
score: 0
Accepted
time: 366ms
memory: 298992kb
input:
300 461 12 142 907 88 715 580 611 713 662 591 617 287 858 967 762 346 774 343 416 338 476 257 288 256 107 303 290 394 583 923 748 844 231 72 223 186 287 742 496 200 500 58 433 346 394 947 701 652 1 487 519 946 460 828 668 345 769 903 492 373 763 432 413 889 483 460 344 426 931 210 10 284 50 967 301 ...
output:
46818188934099
result:
ok 1 number(s): "46818188934099"
Test #87:
score: 0
Accepted
time: 349ms
memory: 297268kb
input:
300 639 305 951 943 715 466 627 157 274 903 734 491 648 121 783 940 235 884 775 733 631 752 555 457 442 346 979 126 809 121 646 342 666 145 804 215 232 339 778 243 435 179 114 529 701 825 184 898 205 377 350 508 776 275 361 163 387 603 649 971 498 66 333 7 213 763 453 605 301 743 102 240 756 817 58 ...
output:
46919036018182
result:
ok 1 number(s): "46919036018182"
Test #88:
score: 0
Accepted
time: 235ms
memory: 300480kb
input:
300 525 899 655 149 12 518 225 625 677 401 631 90 959 414 930 677 913 697 786 129 913 981 633 338 582 839 501 816 583 777 858 590 730 241 174 675 918 103 460 132 681 818 433 48 842 404 266 11 664 385 916 603 161 965 899 734 324 131 164 162 312 6 226 412 18 196 596 738 19 965 557 809 216 241 700 215 ...
output:
-681983295765695
result:
ok 1 number(s): "-681983295765695"
Test #89:
score: 0
Accepted
time: 252ms
memory: 302332kb
input:
300 396 96 779 193 39 86 551 841 405 495 741 572 954 753 124 267 15 574 650 787 948 422 668 115 433 498 103 217 20 50 538 614 214 472 321 109 734 763 612 64 948 701 301 795 263 278 198 527 664 894 577 489 709 182 878 832 159 808 960 850 676 419 120 935 893 464 377 61 433 239 50 843 457 851 759 814 5...
output:
-677281465795462
result:
ok 1 number(s): "-677281465795462"
Test #90:
score: 0
Accepted
time: 399ms
memory: 297784kb
input:
300 118 739 83 147 609 239 583 405 926 133 748 99 917 76 221 678 193 924 583 993 652 642 885 914 904 393 836 941 358 180 319 273 683 173 84 432 910 553 596 187 964 378 687 29 276 308 478 451 44 8 479 602 802 35 573 177 427 144 374 434 511 770 891 518 11 531 19 54 806 73 56 66 996 299 216 430 910 888...
output:
46943361812504
result:
ok 1 number(s): "46943361812504"
Test #91:
score: 0
Accepted
time: 197ms
memory: 297416kb
input:
300 246 584 828 625 671 15 566 393 82 315 188 843 711 613 32 491 108 186 305 938 400 420 394 489 361 601 57 802 671 50 737 839 270 310 384 545 640 628 834 402 257 492 468 187 465 95 586 991 958 666 593 358 87 960 469 411 18 765 525 239 22 579 226 307 746 193 996 474 405 207 605 853 11 811 691 860 70...
output:
451673723530
result:
ok 1 number(s): "451673723530"
Test #92:
score: 0
Accepted
time: 222ms
memory: 297580kb
input:
300 246 584 828 625 671 15 566 393 82 315 188 843 711 613 32 491 108 186 305 938 400 420 394 489 361 601 57 802 671 50 737 839 270 310 384 545 640 628 834 402 257 492 468 187 465 95 586 991 958 666 593 358 87 960 469 411 18 765 525 239 22 579 226 307 746 193 996 474 405 207 605 853 11 811 691 860 70...
output:
450977955794
result:
ok 1 number(s): "450977955794"
Test #93:
score: 0
Accepted
time: 268ms
memory: 298128kb
input:
300 885 856 695 280 342 491 564 599 869 141 31 361 377 996 778 872 68 332 66 169 982 253 766 967 113 827 820 343 515 454 149 827 135 664 884 631 108 257 980 903 300 718 647 887 535 182 759 945 270 468 600 275 232 88 20 414 232 390 54 296 76 573 279 395 816 848 141 764 25 65 55 93 3 561 842 731 60 34...
output:
2213760029414044
result:
ok 1 number(s): "2213760029414044"
Test #94:
score: 0
Accepted
time: 256ms
memory: 297896kb
input:
300 360 958 209 124 969 243 610 633 134 85 174 234 738 66 106 857 149 442 497 678 379 530 64 840 299 554 201 691 929 287 768 612 61 577 913 815 858 118 16 354 727 293 599 391 889 204 292 438 927 843 760 264 357 199 257 101 978 224 992 583 906 683 668 989 948 128 238 433 900 581 651 322 771 329 933 9...
output:
2208243507074189
result:
ok 1 number(s): "2208243507074189"
Test #95:
score: 0
Accepted
time: 250ms
memory: 297864kb
input:
300 949 39 809 627 73 295 401 613 536 584 70 642 754 847 445 594 531 447 804 74 662 759 950 721 439 751 722 677 192 943 84 964 317 673 179 379 352 178 401 539 781 741 214 502 735 784 782 255 282 852 326 359 446 785 795 969 507 752 507 967 527 111 561 394 49 857 381 670 810 99 402 891 935 752 575 349...
output:
658030328579661
result:
ok 1 number(s): "658030328579661"
Test #96:
score: 0
Accepted
time: 252ms
memory: 300332kb
input:
300 116 940 36 671 293 55 430 125 560 677 884 316 44 290 343 185 930 836 372 28 592 200 177 691 994 411 324 566 332 921 764 588 505 905 326 5 655 134 849 767 49 112 786 250 452 361 305 771 578 361 690 540 802 811 774 770 750 429 815 166 187 740 455 917 924 22 162 888 224 373 895 333 768 555 635 948 ...
output:
629107297606369
result:
ok 1 number(s): "629107297606369"
Test #97:
score: 0
Accepted
time: 285ms
memory: 297860kb
input:
300 246 584 828 625 671 15 566 393 82 315 188 843 711 613 32 491 108 186 305 938 400 420 394 489 361 601 57 802 671 50 737 839 270 310 384 545 640 628 834 402 257 492 468 187 465 95 586 991 958 666 593 358 87 960 469 411 18 765 525 239 22 579 226 307 746 193 996 474 405 207 605 853 11 811 691 860 70...
output:
2235042427323169
result:
ok 1 number(s): "2235042427323169"
Test #98:
score: 0
Accepted
time: 260ms
memory: 298496kb
input:
300 885 856 695 280 342 491 564 599 869 141 31 361 377 996 778 872 68 332 66 169 982 253 766 967 113 827 820 343 515 454 149 827 135 664 884 631 108 257 980 903 300 718 647 887 535 182 759 945 270 468 600 275 232 88 20 414 232 390 54 296 76 573 279 395 816 848 141 764 25 65 55 93 3 561 842 731 60 34...
output:
1958343679243611
result:
ok 1 number(s): "1958343679243611"
Test #99:
score: 0
Accepted
time: 262ms
memory: 299000kb
input:
300 360 958 209 124 969 243 610 633 134 85 174 234 738 66 106 857 149 442 497 678 379 530 64 840 299 554 201 691 929 287 768 612 61 577 913 815 858 118 16 354 727 293 599 391 889 204 292 438 927 843 760 264 357 199 257 101 978 224 992 583 906 683 668 989 948 128 238 433 900 581 651 322 771 329 933 9...
output:
1958813431408497
result:
ok 1 number(s): "1958813431408497"
Test #100:
score: 0
Accepted
time: 232ms
memory: 298780kb
input:
300 949 39 809 627 73 295 401 613 536 584 70 642 754 847 445 594 531 447 804 74 662 759 950 721 439 751 722 677 192 943 84 964 317 673 179 379 352 178 401 539 781 741 214 502 735 784 782 255 282 852 326 359 446 785 795 969 507 752 507 967 527 111 561 394 49 857 381 670 810 99 402 891 935 752 575 349...
output:
647626138996332
result:
ok 1 number(s): "647626138996332"
Test #101:
score: 0
Accepted
time: 211ms
memory: 300392kb
input:
300 116 940 36 671 293 55 430 125 560 677 884 316 44 290 343 185 930 836 372 28 592 200 177 691 994 411 324 566 332 921 764 588 505 905 326 5 655 134 849 767 49 112 786 250 452 361 305 771 578 361 690 540 802 811 774 770 750 429 815 166 187 740 455 917 924 22 162 888 224 373 895 333 768 555 635 948 ...
output:
618940478971616
result:
ok 1 number(s): "618940478971616"
Test #102:
score: 0
Accepted
time: 248ms
memory: 298108kb
input:
300 246 584 828 625 671 15 566 393 82 315 188 843 711 613 32 491 108 186 305 938 400 420 394 489 361 601 57 802 671 50 737 839 270 310 384 545 640 628 834 402 257 492 468 187 465 95 586 991 958 666 593 358 87 960 469 411 18 765 525 239 22 579 226 307 746 193 996 474 405 207 605 853 11 811 691 860 70...
output:
1972627915390961
result:
ok 1 number(s): "1972627915390961"
Test #103:
score: 0
Accepted
time: 360ms
memory: 300112kb
input:
300 885 856 695 280 342 491 564 599 869 141 31 361 377 996 778 872 68 332 66 169 982 253 766 967 113 827 820 343 515 454 149 827 135 664 884 631 108 257 980 903 300 718 647 887 535 182 759 945 270 468 600 275 232 88 20 414 232 390 54 296 76 573 279 395 816 848 141 764 25 65 55 93 3 561 842 731 60 34...
output:
46959030714625
result:
ok 1 number(s): "46959030714625"
Test #104:
score: 0
Accepted
time: 343ms
memory: 298020kb
input:
300 360 958 209 124 969 243 610 633 134 85 174 234 738 66 106 857 149 442 497 678 379 530 64 840 299 554 201 691 929 287 768 612 61 577 913 815 858 118 16 354 727 293 599 391 889 204 292 438 927 843 760 264 357 199 257 101 978 224 992 583 906 683 668 989 948 128 238 433 900 581 651 322 771 329 933 9...
output:
46817847063102
result:
ok 1 number(s): "46817847063102"
Test #105:
score: 0
Accepted
time: 243ms
memory: 301724kb
input:
300 949 39 809 627 73 295 401 613 536 584 70 642 754 847 445 594 531 447 804 74 662 759 950 721 439 751 722 677 192 943 84 964 317 673 179 379 352 178 401 539 781 741 214 502 735 784 782 255 282 852 326 359 446 785 795 969 507 752 507 967 527 111 561 394 49 857 381 670 810 99 402 891 935 752 575 349...
output:
-633918267691534
result:
ok 1 number(s): "-633918267691534"
Test #106:
score: 0
Accepted
time: 235ms
memory: 302224kb
input:
300 116 940 36 671 293 55 430 125 560 677 884 316 44 290 343 185 930 836 372 28 592 200 177 691 994 411 324 566 332 921 764 588 505 905 326 5 655 134 849 767 49 112 786 250 452 361 305 771 578 361 690 540 802 811 774 770 750 429 815 166 187 740 455 917 924 22 162 888 224 373 895 333 768 555 635 948 ...
output:
-703769449452908
result:
ok 1 number(s): "-703769449452908"
Test #107:
score: 0
Accepted
time: 405ms
memory: 297748kb
input:
300 246 584 828 625 671 15 566 393 82 315 188 843 711 613 32 491 108 186 305 938 400 420 394 489 361 601 57 802 671 50 737 839 270 310 384 545 640 628 834 402 257 492 468 187 465 95 586 991 958 666 593 358 87 960 469 411 18 765 525 239 22 579 226 307 746 193 996 474 405 207 605 853 11 811 691 860 70...
output:
47221106543754
result:
ok 1 number(s): "47221106543754"
Test #108:
score: 0
Accepted
time: 188ms
memory: 297176kb
input:
300 670 724 86 102 924 280 742 381 237 497 332 587 609 46 59 408 830 744 27 882 853 902 903 872 218 809 574 559 983 217 963 622 561 742 197 441 74 703 775 513 358 903 953 641 654 179 101 531 576 325 411 706 180 484 661 646 904 386 572 851 726 196 561 585 969 854 781 597 899 341 257 639 730 26 567 99...
output:
451572966849
result:
ok 1 number(s): "451572966849"
Test #109:
score: 0
Accepted
time: 191ms
memory: 296744kb
input:
300 670 724 86 102 924 280 742 381 237 497 332 587 609 46 59 408 830 744 27 882 853 902 903 872 218 809 574 559 983 217 963 622 561 742 197 441 74 703 775 513 358 903 953 641 654 179 101 531 576 325 411 706 180 484 661 646 904 386 572 851 726 196 561 585 969 854 781 597 899 341 257 639 730 26 567 99...
output:
450874817464
result:
ok 1 number(s): "450874817464"
Test #110:
score: 0
Accepted
time: 288ms
memory: 317080kb
input:
300 14 701 249 758 404 460 443 587 24 27 278 104 467 533 101 789 983 82 84 410 731 839 275 350 378 36 234 500 827 132 863 97 722 800 289 528 542 628 921 822 593 833 428 341 531 266 570 189 696 127 714 623 517 612 916 649 119 11 613 804 292 190 911 969 847 214 222 592 624 199 412 879 826 73 613 161 5...
output:
2217655800871989
result:
ok 1 number(s): "2217655800871989"
Test #111:
score: 0
Accepted
time: 289ms
memory: 309440kb
input:
300 488 802 955 602 222 211 81 325 289 971 613 978 828 795 725 774 872 192 515 726 832 308 573 519 564 762 422 744 242 157 994 395 648 714 918 223 588 489 957 568 828 216 676 846 78 288 807 682 545 798 577 508 154 723 449 336 569 845 847 387 417 788 3 371 979 981 215 365 691 715 496 109 786 737 809 ...
output:
2193374316293719
result:
ok 1 number(s): "2193374316293719"
Test #112:
score: 0
Accepted
time: 248ms
memory: 310536kb
input:
300 77 884 362 809 623 368 384 601 691 470 214 681 140 384 768 511 958 710 822 123 603 641 459 593 296 664 239 538 16 622 502 234 608 809 288 979 81 549 639 457 778 151 699 853 924 571 889 499 196 511 440 603 540 413 691 715 97 373 66 475 230 728 896 671 81 222 62 793 409 233 951 485 950 968 154 76 ...
output:
714394078247522
result:
ok 1 number(s): "714394078247522"
Test #113:
score: 0
Accepted
time: 258ms
memory: 311316kb
input:
300 244 785 782 44 355 832 709 817 420 156 324 868 838 723 962 102 652 883 390 972 341 489 687 370 851 323 545 131 452 791 990 963 92 41 435 118 385 913 791 878 46 34 375 408 448 149 821 15 196 20 804 488 791 335 966 5 532 946 862 970 890 845 494 195 660 683 139 12 823 507 444 415 487 771 214 378 42...
output:
622967920315989
result:
ok 1 number(s): "622967920315989"
Test #114:
score: 0
Accepted
time: 270ms
memory: 309540kb
input:
300 670 724 86 102 924 280 742 381 237 497 332 587 609 46 59 408 830 744 27 882 853 902 903 872 218 809 574 559 983 217 963 622 561 742 197 441 74 703 775 513 358 903 953 641 654 179 101 531 576 325 411 706 180 484 661 646 904 386 572 851 726 196 561 585 969 854 781 597 899 341 257 639 730 26 567 99...
output:
2234736050960383
result:
ok 1 number(s): "2234736050960383"
Test #115:
score: 0
Accepted
time: 266ms
memory: 310476kb
input:
300 14 701 249 758 404 460 443 587 24 27 278 104 467 533 101 789 983 82 84 410 731 839 275 350 378 36 234 500 827 132 863 97 722 800 289 528 542 628 921 822 593 833 428 341 531 266 570 189 696 127 714 623 517 612 916 649 119 11 613 804 292 190 911 969 847 214 222 592 624 199 412 879 826 73 613 161 5...
output:
1963476857157220
result:
ok 1 number(s): "1963476857157220"
Test #116:
score: 0
Accepted
time: 227ms
memory: 310136kb
input:
300 488 802 955 602 222 211 81 325 289 971 613 978 828 795 725 774 872 192 515 726 832 308 573 519 564 762 422 744 242 157 994 395 648 714 918 223 588 489 957 568 828 216 676 846 78 288 807 682 545 798 577 508 154 723 449 336 569 845 847 387 417 788 3 371 979 981 215 365 691 715 496 109 786 737 809 ...
output:
1946507305944506
result:
ok 1 number(s): "1946507305944506"
Test #117:
score: 0
Accepted
time: 226ms
memory: 310964kb
input:
300 77 884 362 809 623 368 384 601 691 470 214 681 140 384 768 511 958 710 822 123 603 641 459 593 296 664 239 538 16 622 502 234 608 809 288 979 81 549 639 457 778 151 699 853 924 571 889 499 196 511 440 603 540 413 691 715 97 373 66 475 230 728 896 671 81 222 62 793 409 233 951 485 950 968 154 76 ...
output:
704055144169576
result:
ok 1 number(s): "704055144169576"
Test #118:
score: 0
Accepted
time: 234ms
memory: 311680kb
input:
300 244 785 782 44 355 832 709 817 420 156 324 868 838 723 962 102 652 883 390 972 341 489 687 370 851 323 545 131 452 791 990 963 92 41 435 118 385 913 791 878 46 34 375 408 448 149 821 15 196 20 804 488 791 335 966 5 532 946 862 970 890 845 494 195 660 683 139 12 823 507 444 415 487 771 214 378 42...
output:
614138501710819
result:
ok 1 number(s): "614138501710819"
Test #119:
score: 0
Accepted
time: 253ms
memory: 309488kb
input:
300 670 724 86 102 924 280 742 381 237 497 332 587 609 46 59 408 830 744 27 882 853 902 903 872 218 809 574 559 983 217 963 622 561 742 197 441 74 703 775 513 358 903 953 641 654 179 101 531 576 325 411 706 180 484 661 646 904 386 572 851 726 196 561 585 969 854 781 597 899 341 257 639 730 26 567 99...
output:
1972699441486447
result:
ok 1 number(s): "1972699441486447"
Test #120:
score: 0
Accepted
time: 358ms
memory: 310688kb
input:
300 14 701 249 758 404 460 443 587 24 27 278 104 467 533 101 789 983 82 84 410 731 839 275 350 378 36 234 500 827 132 863 97 722 800 289 528 542 628 921 822 593 833 428 341 531 266 570 189 696 127 714 623 517 612 916 649 119 11 613 804 292 190 911 969 847 214 222 592 624 199 412 879 826 73 613 161 5...
output:
46984005244639
result:
ok 1 number(s): "46984005244639"
Test #121:
score: 0
Accepted
time: 346ms
memory: 313152kb
input:
300 488 802 955 602 222 211 81 325 289 971 613 978 828 795 725 774 872 192 515 726 832 308 573 519 564 762 422 744 242 157 994 395 648 714 918 223 588 489 957 568 828 216 676 846 78 288 807 682 545 798 577 508 154 723 449 336 569 845 847 387 417 788 3 371 979 981 215 365 691 715 496 109 786 737 809 ...
output:
46567938864103
result:
ok 1 number(s): "46567938864103"
Test #122:
score: 0
Accepted
time: 240ms
memory: 312448kb
input:
300 77 884 362 809 623 368 384 601 691 470 214 681 140 384 768 511 958 710 822 123 603 641 459 593 296 664 239 538 16 622 502 234 608 809 288 979 81 549 639 457 778 151 699 853 924 571 889 499 196 511 440 603 540 413 691 715 97 373 66 475 230 728 896 671 81 222 62 793 409 233 951 485 950 968 154 76 ...
output:
-679853926272551
result:
ok 1 number(s): "-679853926272551"
Test #123:
score: 0
Accepted
time: 234ms
memory: 314056kb
input:
300 244 785 782 44 355 832 709 817 420 156 324 868 838 723 962 102 652 883 390 972 341 489 687 370 851 323 545 131 452 791 990 963 92 41 435 118 385 913 791 878 46 34 375 408 448 149 821 15 196 20 804 488 791 335 966 5 532 946 862 970 890 845 494 195 660 683 139 12 823 507 444 415 487 771 214 378 42...
output:
-638346237080837
result:
ok 1 number(s): "-638346237080837"
Test #124:
score: 0
Accepted
time: 405ms
memory: 309628kb
input:
300 670 724 86 102 924 280 742 381 237 497 332 587 609 46 59 408 830 744 27 882 853 902 903 872 218 809 574 559 983 217 963 622 561 742 197 441 74 703 775 513 358 903 953 641 654 179 101 531 576 325 411 706 180 484 661 646 904 386 572 851 726 196 561 585 969 854 781 597 899 341 257 639 730 26 567 99...
output:
47352531514674
result:
ok 1 number(s): "47352531514674"