QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#792173 | #9272. Fun at Luggage Claim | bulijiojiodibuliduo# | AC ✓ | 17ms | 5300kb | C++17 | 1.3kb | 2024-11-29 03:31:11 | 2024-11-29 03:31:13 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
#define rep(i,a,n) for (int i=a;i<n;i++)
#define per(i,a,n) for (int i=n-1;i>=a;i--)
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define all(x) (x).begin(),(x).end()
#define fi first
#define se second
#define SZ(x) ((int)(x).size())
typedef vector<int> VI;
typedef basic_string<int> BI;
typedef long long ll;
typedef pair<int,int> PII;
typedef double db;
mt19937 mrand(random_device{}());
const ll mod=1000000007;
int rnd(int x) { return mrand() % x;}
ll powmod(ll a,ll b) {ll res=1;a%=mod; assert(b>=0); for(;b;b>>=1){if(b&1)res=res*a%mod;a=a*a%mod;}return res;}
ll gcd(ll a,ll b) { return b?gcd(b,a%b):a;}
// head
const int N=101000;
int n,a[N],b[N],lag[N];
bool solve() {
rep(i,0,n) lag[i]=a[i]>b[i];
rep(i,0,n) if (lag[i]&&lag[(i+1)%n]) {
return false;
}
VI op;
rep(i,0,n) if (lag[i]) op.pb(i);
sort(all(op),[&](int x,int y) {
return b[x]<b[y];
});
for (auto u:op) {
if ((a[u]-b[u])%2!=0) return false;
int d=(a[u]-b[u])/2;
a[u]-=2*d;
a[(u+1)%n]+=d;
a[(u+n-1)%n]+=d;
if (a[u]<max(a[(u+1)%n],a[(u+n-1)%n])-1) return false;
}
rep(i,0,n) if (a[i]!=b[i]) return false;
return true;
}
int main() {
scanf("%d",&n);
rep(i,0,n) scanf("%d",&a[i]);
rep(i,0,n) scanf("%d",&b[i]);
puts(solve()?"Yes":"No");
}
详细
Test #1:
score: 100
Accepted
time: 0ms
memory: 3760kb
input:
3 0 0 2 1 1 0
output:
Yes
result:
ok "Yes"
Test #2:
score: 0
Accepted
time: 0ms
memory: 3632kb
input:
3 0 2 0 0 1 1
output:
No
result:
ok "No"
Test #3:
score: 0
Accepted
time: 0ms
memory: 3720kb
input:
4 0 100 0 10 33 40 33 4
output:
Yes
result:
ok "Yes"
Test #4:
score: 0
Accepted
time: 0ms
memory: 3996kb
input:
3 2 2 2 1 1 1
output:
No
result:
ok "No"
Test #5:
score: 0
Accepted
time: 0ms
memory: 3600kb
input:
3 0 0 0 0 0 0
output:
Yes
result:
ok "Yes"
Test #6:
score: 0
Accepted
time: 0ms
memory: 3664kb
input:
3 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000
output:
Yes
result:
ok "Yes"
Test #7:
score: 0
Accepted
time: 0ms
memory: 3664kb
input:
10 5 2 13 5 17 14 5 14 12 13 19 3 12 3 5 7 19 17 2 13
output:
No
result:
ok "No"
Test #8:
score: 0
Accepted
time: 0ms
memory: 3632kb
input:
10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10 10
output:
Yes
result:
ok "Yes"
Test #9:
score: 0
Accepted
time: 0ms
memory: 3628kb
input:
10 13 30 1 0 7 5 12 1 1 30 7 2 11 14 8 14 23 8 2 11
output:
No
result:
ok "No"
Test #10:
score: 0
Accepted
time: 0ms
memory: 3980kb
input:
10 10 1 1 12 17 20 3 14 11 11 9 1 8 16 20 7 3 12 5 17
output:
No
result:
ok "No"
Test #11:
score: 0
Accepted
time: 0ms
memory: 3756kb
input:
10 9 10 10 10 10 9 10 10 10 10 10 10 10 10 10 10 10 10 10 10
output:
No
result:
ok "No"
Test #12:
score: 0
Accepted
time: 8ms
memory: 5124kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
No
result:
ok "No"
Test #13:
score: 0
Accepted
time: 8ms
memory: 5152kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
No
result:
ok "No"
Test #14:
score: 0
Accepted
time: 8ms
memory: 5152kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
No
result:
ok "No"
Test #15:
score: 0
Accepted
time: 10ms
memory: 4788kb
input:
100000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000...
output:
Yes
result:
ok "Yes"
Test #16:
score: 0
Accepted
time: 9ms
memory: 4808kb
input:
100000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000...
output:
No
result:
ok "No"
Test #17:
score: 0
Accepted
time: 14ms
memory: 4864kb
input:
100000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000000 1000000...
output:
No
result:
ok "No"
Test #18:
score: 0
Accepted
time: 0ms
memory: 3668kb
input:
10 0 36 0 0 0 0 0 0 0 0 12 12 12 0 0 0 0 0 0 0
output:
Yes
result:
ok "Yes"
Test #19:
score: 0
Accepted
time: 0ms
memory: 3760kb
input:
10 46 0 0 0 0 0 0 0 0 0 16 15 0 0 0 0 0 0 0 15
output:
Yes
result:
ok "Yes"
Test #20:
score: 0
Accepted
time: 0ms
memory: 3664kb
input:
10 0 0 0 0 55 0 0 0 0 0 0 0 0 18 19 18 0 0 0 0
output:
Yes
result:
ok "Yes"
Test #21:
score: 0
Accepted
time: 0ms
memory: 3988kb
input:
10 46 27 0 0 0 0 0 0 0 88 60 27 0 0 0 0 0 0 14 60
output:
Yes
result:
ok "Yes"
Test #22:
score: 0
Accepted
time: 0ms
memory: 3760kb
input:
10 10 0 12 0 0 56 0 0 0 0 3 6 6 4 19 18 19 0 0 3
output:
No
result:
ok "No"
Test #23:
score: 0
Accepted
time: 0ms
memory: 3708kb
input:
10 0 22 0 10 0 0 0 54 0 0 7 8 8 7 0 0 18 18 19 1
output:
No
result:
ok "No"
Test #24:
score: 0
Accepted
time: 0ms
memory: 3692kb
input:
10 38 80 37 65 41 31 18 15 54 6 52 52 56 55 46 31 18 28 28 19
output:
Yes
result:
ok "Yes"
Test #25:
score: 0
Accepted
time: 0ms
memory: 3692kb
input:
10 26 38 77 62 28 99 56 44 87 7 27 42 67 67 42 71 70 58 59 21
output:
No
result:
ok "No"
Test #26:
score: 0
Accepted
time: 0ms
memory: 3692kb
input:
10 32 28 70 68 5 19 66 16 68 66 32 29 70 69 4 35 33 33 66 67
output:
No
result:
ok "No"
Test #27:
score: 0
Accepted
time: 0ms
memory: 3764kb
input:
10 56 64 100 47 57 85 70 1 33 45 56 76 76 59 62 75 75 1 33 45
output:
Yes
result:
ok "Yes"
Test #28:
score: 0
Accepted
time: 0ms
memory: 3980kb
input:
10 43 17 5 14 71 62 18 40 56 45 43 17 5 15 69 63 18 41 54 46
output:
Yes
result:
ok "Yes"
Test #29:
score: 0
Accepted
time: 0ms
memory: 3640kb
input:
10 94 90 80 97 5 16 40 19 11 45 94 90 85 87 10 23 26 26 11 45
output:
Yes
result:
ok "Yes"
Test #30:
score: 0
Accepted
time: 0ms
memory: 3696kb
input:
10 25 78 79 42 59 51 7 91 11 89 46 78 79 45 53 54 27 51 52 47
output:
Yes
result:
ok "Yes"
Test #31:
score: 0
Accepted
time: 0ms
memory: 3988kb
input:
10 14 49 97 28 50 14 15 80 96 90 14 50 95 30 48 15 15 81 94 91
output:
Yes
result:
ok "Yes"
Test #32:
score: 0
Accepted
time: 0ms
memory: 3980kb
input:
10 96 73 38 70 8 37 12 32 11 38 84 79 45 56 15 37 14 28 13 44
output:
Yes
result:
ok "Yes"
Test #33:
score: 0
Accepted
time: 0ms
memory: 3756kb
input:
10 43 43 58 64 87 59 79 77 9 50 45 43 58 72 71 68 77 78 11 46
output:
Yes
result:
ok "Yes"
Test #34:
score: 0
Accepted
time: 0ms
memory: 3704kb
input:
10 73 39 30 46 5 61 56 16 5 100 74 39 31 44 7 59 57 16 6 98
output:
Yes
result:
ok "Yes"
Test #35:
score: 0
Accepted
time: 0ms
memory: 3708kb
input:
10 23 67 47 91 31 95 85 94 13 79 38 63 63 63 47 91 89 90 28 53
output:
Yes
result:
ok "Yes"
Test #36:
score: 0
Accepted
time: 0ms
memory: 3644kb
input:
10 72 34 71 31 36 20 46 10 2 59 65 49 49 42 36 29 28 19 2 62
output:
No
result:
ok "No"
Test #37:
score: 0
Accepted
time: 0ms
memory: 3716kb
input:
10 9 14 56 19 6 70 85 96 35 85 10 15 54 20 6 70 85 94 38 83
output:
No
result:
ok "No"
Test #38:
score: 0
Accepted
time: 0ms
memory: 3952kb
input:
10 28 35 94 91 71 4 19 90 91 71 28 36 92 91 72 4 19 90 91 71
output:
No
result:
ok "No"
Test #39:
score: 0
Accepted
time: 0ms
memory: 3636kb
input:
10 53 58 46 99 16 12 53 50 79 69 53 57 64 63 34 12 53 53 74 72
output:
No
result:
ok "No"
Test #40:
score: 0
Accepted
time: 0ms
memory: 3760kb
input:
10 70 82 95 6 31 62 8 25 14 35 70 83 94 7 32 60 10 23 14 35
output:
No
result:
ok "No"
Test #41:
score: 0
Accepted
time: 0ms
memory: 3644kb
input:
10 40 93 73 50 46 34 23 95 18 71 54 79 80 50 46 33 26 91 27 57
output:
No
result:
ok "No"
Test #42:
score: 0
Accepted
time: 0ms
memory: 3712kb
input:
10 39 9 60 33 88 89 26 3 69 74 41 18 42 42 88 89 25 4 71 70
output:
No
result:
ok "No"
Test #43:
score: 0
Accepted
time: 0ms
memory: 3664kb
input:
10 5 20 18 14 30 98 94 10 47 6 6 18 19 14 31 95 95 12 45 7
output:
No
result:
ok "No"
Test #44:
score: 0
Accepted
time: 0ms
memory: 3980kb
input:
10 53 89 41 67 68 40 91 17 2 90 64 77 47 67 68 44 83 21 7 80
output:
Yes
result:
ok "Yes"
Test #45:
score: 0
Accepted
time: 17ms
memory: 4932kb
input:
99999 198398524 413642673 959630483 279274771 232900292 968749831 500318273 993421538 490919360 644858609 865177242 289834091 809862373 23997493 288175376 915374991 46377855 620229969 950512053 305537998 399922097 88362824 715967274 988746377 378349506 941394342 924142751 519776780 833217764 5699879...
output:
Yes
result:
ok "Yes"
Test #46:
score: 0
Accepted
time: 12ms
memory: 4984kb
input:
99999 98088352 574228943 600145807 929789688 908299979 568075829 949578184 987287935 519640622 764839178 400122891 988789500 527769377 718891591 655158706 606456035 620682522 88726537 782643122 100894785 348994015 154832331 241675446 784240564 557378097 17251928 369675176 120941253 260381031 5003801...
output:
Yes
result:
ok "Yes"
Test #47:
score: 0
Accepted
time: 13ms
memory: 4980kb
input:
99999 94401511 770931784 690907344 540200216 186844573 827442137 859345040 718292550 780643492 244938253 809264966 398091974 749810570 918986933 54965776 715228012 77720907 721647071 904791395 650413520 660004505 490959535 193450581 513080221 616819124 840900113 2619942 395837075 274105995 789479797...
output:
Yes
result:
ok "Yes"
Test #48:
score: 0
Accepted
time: 10ms
memory: 4928kb
input:
99999 26231420 134646084 223437284 142025269 801636166 870483935 51182747 888817107 447405268 930237062 933698164 815154837 625579203 468718978 589225931 531957311 359968819 501443039 514438242 775543102 657194169 36043988 634509234 347476253 893908667 260355718 609525107 388574582 871736190 6253405...
output:
Yes
result:
ok "Yes"
Test #49:
score: 0
Accepted
time: 14ms
memory: 4896kb
input:
99999 315626512 473069615 836116171 268530654 333792095 660854562 68737983 156188233 883299462 624912903 380340715 382278891 918697910 386506508 548880701 142909461 134553051 140845102 279757449 612089646 506963269 244353629 762429968 241111414 659995568 111854804 577523573 391165900 525900504 25794...
output:
Yes
result:
ok "Yes"
Test #50:
score: 0
Accepted
time: 14ms
memory: 5116kb
input:
99999 900523621 263000306 296189513 422795320 566864387 515396643 404499233 879074495 665296988 817448525 708990486 279724678 410132276 280493483 685636084 48989882 48403465 410479507 207058578 795683212 88994700 562473001 371957601 43098649 261747245 598759945 177395756 59855755 451536837 117954067...
output:
Yes
result:
ok "Yes"
Test #51:
score: 0
Accepted
time: 16ms
memory: 4924kb
input:
99999 610185663 596325447 118430905 786626989 463477517 522649341 210596687 463547259 888330548 517613073 192759284 435201853 21280008 839660800 779841470 124918143 908710785 757357660 103995001 721440661 314846606 999861853 791851621 421539777 490634879 375643164 909364124 188228976 576568540 21755...
output:
No
result:
ok "No"
Test #52:
score: 0
Accepted
time: 17ms
memory: 5056kb
input:
99999 799053885 229971749 862422549 684930611 208318389 133632444 205428234 943407411 3396920 498363081 615701639 903466162 749369463 671281331 32182794 965169671 433503619 504885190 585995631 861253651 85353336 640523767 894341483 434662702 707570835 866865605 420862145 7594640 20401354 815447962 2...
output:
No
result:
ok "No"
Test #53:
score: 0
Accepted
time: 16ms
memory: 5052kb
input:
99999 393636895 174294105 56662956 148400499 452664243 383256419 448951071 284238025 914177959 273060774 580679497 567974697 389895050 229767826 930722509 708121978 876990500 25794209 956549831 484437218 766920526 673499529 576175081 817177609 548654641 54335429 157370948 570360942 217393153 1346113...
output:
No
result:
ok "No"
Test #54:
score: 0
Accepted
time: 8ms
memory: 4776kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #55:
score: 0
Accepted
time: 8ms
memory: 4800kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #56:
score: 0
Accepted
time: 8ms
memory: 4860kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #57:
score: 0
Accepted
time: 5ms
memory: 5160kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #58:
score: 0
Accepted
time: 8ms
memory: 4864kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #59:
score: 0
Accepted
time: 8ms
memory: 4880kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #60:
score: 0
Accepted
time: 10ms
memory: 4956kb
input:
100000 0 173352243 0 0 0 0 0 0 0 0 0 525775467 0 0 0 0 0 0 0 0 0 0 0 262432286 0 0 0 0 0 533543840 456540422 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 258978182 0 0 0 0 596077287 0 0 0 0 0 0 0 851063305 0 0 0 0 0 0 0 0 0 0 0 0 538312126 205002930 0 0 0 0 0 0 0 0 0 0 0 0 0 0...
output:
Yes
result:
ok "Yes"
Test #61:
score: 0
Accepted
time: 10ms
memory: 5260kb
input:
100000 0 0 0 148107907 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 84983104 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 298615069 0 0 0 0 0 0 0 0 0 0 0 496500986 0 74025205 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 808074872 374607842 0 0 0 0 0 0 0 0 0 0 0 0 724322008 0 133472349 0 0 0 329730724 0 0 245261979 734139013 0 0 0...
output:
Yes
result:
ok "Yes"
Test #62:
score: 0
Accepted
time: 10ms
memory: 4900kb
input:
100000 0 0 0 0 0 0 0 0 0 0 0 0 639258390 0 0 0 0 0 0 0 0 0 833150689 0 0 0 922375406 0 0 0 0 0 0 0 0 236611117 773153493 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 966666529 0 0 0 0 0 0 0 0 0 0 0 241976476 0 0 0 760212916 0 0 0 437577343 0 0 0 0 0 0 325820001 0 0 632338334 0 0 0 0 0 0 0 0 55052041 0 0 0 0 0 0 ...
output:
Yes
result:
ok "Yes"
Test #63:
score: 0
Accepted
time: 8ms
memory: 5048kb
input:
100000 471810801 28581832 842157222 826446481 526801877 538815724 830509295 29151191 444615959 507669127 724553898 129143443 595227396 255279613 345894859 723628310 67559178 216398742 336258197 56370530 249259692 145632802 489350091 953195546 668584102 745314299 276796699 933565021 869422400 2150897...
output:
Yes
result:
ok "Yes"
Test #64:
score: 0
Accepted
time: 12ms
memory: 4960kb
input:
100000 993673553 635427434 289314762 936350007 33124508 8222551 481062973 981915506 810102170 632537479 814441632 328903931 436862650 50985922 676679476 222981641 360130480 40113651 800996102 830134787 234401304 130105751 713472890 146791236 407352616 410302795 589206022 734361972 286424400 82240579...
output:
Yes
result:
ok "Yes"
Test #65:
score: 0
Accepted
time: 17ms
memory: 5300kb
input:
100000 652396223 653861248 24065161 380046803 663244027 311224941 524855936 979317101 56084600 6870931 936615048 636005702 250932098 843810135 34879591 142254624 844187276 139110354 78689457 641830004 512118839 843245017 459450797 159060482 190271538 570163911 220993716 462235218 213074834 445133940...
output:
Yes
result:
ok "Yes"
Test #66:
score: 0
Accepted
time: 16ms
memory: 5000kb
input:
100000 604246162 219161631 999294435 80383122 472967701 958429938 916709303 968548864 394882214 462861459 182657844 667915128 729454906 198088119 577030497 230286689 659025949 283649642 246067948 203197892 181144862 873976755 914350802 710800304 901261346 936099026 539814641 509437683 87938503 96360...
output:
Yes
result:
ok "Yes"
Test #67:
score: 0
Accepted
time: 13ms
memory: 5020kb
input:
100000 479128688 790906521 578243757 932796135 426039253 195988305 857810666 762956310 214368742 856186059 447284164 360587135 167062053 417597542 309163250 219840886 404478720 516478149 67407893 606613113 185190865 596883173 69727640 26744683 572538127 440131260 836817745 172453374 315569592 116761...
output:
Yes
result:
ok "Yes"
Test #68:
score: 0
Accepted
time: 10ms
memory: 4988kb
input:
100000 284592918 167076132 723054041 600154308 907936919 13142353 690292128 695425334 990661270 633682870 708873243 635294711 315894301 569479906 387905456 368303787 736097631 755781148 242968518 698909371 694274443 65740775 706639006 10862067 418616484 117948904 657292050 121121702 320759985 476570...
output:
Yes
result:
ok "Yes"
Test #69:
score: 0
Accepted
time: 16ms
memory: 5056kb
input:
100000 23403767 508255630 233925180 321068573 258328045 684855511 67366353 941813426 610641517 101174723 2634886 450004538 373890944 301425785 149090855 527547248 66552502 253943773 768434291 737720515 683397208 874896475 252647312 27320077 152727493 820907122 908142500 730993336 84686113 370776382 ...
output:
Yes
result:
ok "Yes"
Test #70:
score: 0
Accepted
time: 17ms
memory: 4936kb
input:
100000 929493517 113792727 619308357 375931221 880899697 845551063 823449431 458329161 849465762 205229701 392287779 714646075 166023845 132745369 692862660 95762786 870331160 285588258 828791250 407092414 59088393 609356584 38272877 825843249 832671226 3222569 105671695 308986880 405136337 39052547...
output:
Yes
result:
ok "Yes"
Test #71:
score: 0
Accepted
time: 17ms
memory: 4932kb
input:
100000 178297930 249289073 547946081 10233805 25169331 140417622 954434778 720868931 356877636 22375581 930866246 46688164 78231387 550318092 251744903 918557654 701716461 685089367 571412122 784843642 105454241 265570969 138953671 837327187 790155854 235307111 887692064 444077403 115862925 77296530...
output:
Yes
result:
ok "Yes"
Test #72:
score: 0
Accepted
time: 12ms
memory: 5288kb
input:
100000 277411745 178170199 767208201 683257145 422829336 483389488 388915359 186136995 887482373 760364485 311833010 132338378 940043306 996148877 420306968 89139529 122969072 370963212 526014147 802233731 254556844 931298608 143420930 818397517 734790765 708036727 223757866 409939151 573638358 5145...
output:
No
result:
ok "No"
Test #73:
score: 0
Accepted
time: 16ms
memory: 4984kb
input:
100000 475235032 923445279 619968117 281795118 203630106 860202705 47017396 135193836 465100453 990079512 200003939 254014828 234871305 624918400 672083005 202560645 561942479 610108792 698488117 656494605 291158923 862570212 699951684 15819807 202932555 661151864 682876330 717581011 233863145 34088...
output:
No
result:
ok "No"
Test #74:
score: 0
Accepted
time: 17ms
memory: 5052kb
input:
100000 849835765 731367934 656041770 954662796 311531575 481721698 631639395 149077834 700885812 66176562 747045555 259171888 47735143 692421709 394270410 692238932 74272741 698984031 34888805 67294272 401605203 767981790 524608600 760787233 671767065 959582146 270565115 651227072 32529174 525446695...
output:
No
result:
ok "No"
Test #75:
score: 0
Accepted
time: 16ms
memory: 4984kb
input:
100000 972718832 635003361 490059710 687214896 108465518 637139662 959086189 18560516 226758084 614240724 731280057 47236047 749999010 120478020 66081269 758620928 705401166 404334742 905249920 925717824 540701391 10188768 257181181 562984257 758469536 207913343 320372402 522690847 778624935 2484963...
output:
No
result:
ok "No"
Test #76:
score: 0
Accepted
time: 16ms
memory: 4924kb
input:
100000 610733801 316123590 284068300 791826000 387256275 300243637 646788803 653287950 14910793 552064279 821283101 803960665 987005717 635831699 694800420 618585271 469348275 931473303 860733061 905916025 552546195 465128114 478742414 667806751 481835774 598521869 964563134 924054737 25562515 34408...
output:
No
result:
ok "No"
Test #77:
score: 0
Accepted
time: 17ms
memory: 4988kb
input:
100000 527099908 941460705 878546464 291542503 863585994 33183214 9817356 507608718 764019000 495356870 15352662 697933025 884201534 548674173 174740953 691396265 910438673 349299480 837041826 715632766 17034221 587538472 725675490 251435872 783483893 86413918 664968929 341042379 304066487 558731084...
output:
No
result:
ok "No"
Test #78:
score: 0
Accepted
time: 16ms
memory: 4988kb
input:
100000 743833489 987003102 213422862 115276388 149514091 329621588 674198421 891569924 295066362 70957887 840155267 813767856 777249033 680262465 189753023 990776803 163248914 712337471 331635768 574676201 368487529 766046337 624286983 248506167 515570803 392119532 828332856 191700019 94362020 60308...
output:
No
result:
ok "No"
Test #79:
score: 0
Accepted
time: 13ms
memory: 5008kb
input:
100000 229360278 71157529 368867194 808198738 385111995 84872536 892646472 808685470 207463068 80999664 87390470 870914113 500737739 738402089 706079793 289030442 857590207 792378724 257042843 512963175 399522840 780461225 878591130 565824040 754369210 569104340 30344722 554036093 503129374 35056976...
output:
No
result:
ok "No"
Test #80:
score: 0
Accepted
time: 16ms
memory: 5276kb
input:
100000 111023864 493866073 700142130 963128986 207687256 257566855 478929084 232827482 639769675 645878722 86421000 149022805 514955773 59307749 816246635 446652806 351534634 56723926 82667643 542608777 159218005 712782117 294107907 970729561 671592090 133468250 199818234 316387875 722451227 9641780...
output:
No
result:
ok "No"
Extra Test:
score: 0
Extra Test Passed