# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
1012423 |
2024-07-02T06:36:54 Z |
modwwe |
Two Dishes (JOI19_dishes) |
C++17 |
|
2388 ms |
158544 KB |
//https://www.instagram.com/_modwwe/
#pragma GCC optimize("Ofast")
//#pragma GCC target("avx2,bmi,bmi2")
#include<bits/stdc++.h>
#define int long long
//#define ll long long
#define down cout<<'\n';
#define debug cout<<" cucuucucuuu",down
#define NHP ios_base::sync_with_stdio(0);cout.tie(0);cin.tie(0);
#define modwwe int t;cin>>t; while(t--)
#define bit(i,j) (i>>j&1)
#define sobit(a) __builtin_popcountll(a)
#define task "test"
#define fin(x) freopen(x".inp","r",stdin)
#define fou(x) freopen(x".ans ","w",stdout)
#define pb push_back
#define checktime cerr << (double)clock() / CLOCKS_PER_SEC * 1000 << " ms";
using namespace std;
void phongbeo();
const int inf=1e18;
const int mod2=1e9+7;
const int mod1=998244353;
struct icd
{
int a,b;
};
struct ib
{
int a;
int b;
};
struct ic
{
int a,b,c;
};
struct id
{
int a,b,c,d;
};
struct ie
{
int a,b,c, d,e,f;
};
int n,m,s0,s1,s2,s4,s3,sf,k,r,mid,s5,s6,mx,s7,s8,s9,mx2,res,dem2=0,dem=0,l,l2,r2,l3,l4;
int i,s10,s12;
int el=29;
main()
{
#ifndef ONLINE_JUDGE
// fin(task),fou(task);
#endif
NHP
/// cin>>s1;
// modwwe
phongbeo(),down
}
struct IT
{
ib t[4000011];
void ff(int x)
{
for(int i=x*2; i<=x*2+1; i++)
t[i].a+=t[x].b,
t[i].b+=t[x].b;
t[x].b=0;
}
void build(int node,int l,int r)
{
t[node].a=-inf;
if(l==0&&r==0) t[node].a=0;
if(l==r) return;
int mid=l+r>>1;
build(node<<1,l,mid);
build(node<<1|1,mid+1,r);
t[node].a=max(t[node<<1].a,t[node<<1|1].a);
}
void upd2(int node,int l,int r,int l1,int c)
{
if(l==r)
{
t[node].a=max(t[node].a,c) ;
return;
}
int mid=l+r>>1;
ff(node);
if(l1<=mid) upd2(node<<1,l,mid,l1,c);
else upd2(node<<1|1,mid+1,r,l1,c);
t[node].a=max(t[node<<1].a,t[node<<1|1].a);
}
void upd(int node,int l,int r,int l1,int r1,int c)
{
if(l>r1||r<l1) return;
if(l>=l1&&r<=r1)
{
t[node].a+=c;
t[node].b+=c;
return;
}
int mid=l+r>>1;
ff(node);
upd(node<<1,l,mid,l1,r1,c);
upd(node<<1|1,mid+1,r,l1,r1,c);
t[node].a=max(t[node<<1].a,t[node<<1|1].a);
}
int get(int node,int l,int r,int l1,int r1)
{
if(l>r1||r1<l1) return -inf;
if(l>=l1&&r<=r1) return t[node].a;
int mid=l+r>>1;
ff(node);
return max(get(node<<1,l,mid,l1,r1),get(node<<1|1,mid+1,r,l1,r1));
}
} st;
struct FEN
{
int bit[1000007];
void upd(int x,int y)
{
for(x; x<=m; x+=x&-x)bit[x]+=y;
}
int get(int x)
{
int s=0;
for(x; x; x-=x&-x) s+=bit[x];
return s;
}
} fe;
ic a[1000007];
ic b[1000007];
vector<int> v[1000007];
vector<int> v3;
vector<int> v4;
void phongbeo()
{
cin>>n>>m;
for(int i=1; i<=n; i++)
cin>>a[i].a>>a[i].b>>a[i].c,
a[i].a+=a[i-1].a,
v3.pb(a[i].a);
for(int i=1; i<=m; i++)
cin>>b[i].a>>b[i].b>>b[i].c,
b[i].a+=b[i-1].a,
v4.pb(b[i].a);
st.build(1,0,m);
for(int i=1; i<=m; i++)
{
s2=b[i].b-b[i].a;
if(s2>=0)
{
fe.upd(i,b[i].c);
s2=upper_bound(v3.begin(),v3.end(),s2)-v3.begin()+1;
v[s2].pb(i);
}
}
for(int i=1; i<=n; i++)
{
for(auto x:v[i])
{
s2=st.get(1,0,m,0,x);
st.upd2(1,0,m,x,s2);
}
if(a[i].b-a[i].a>=0)
{
s3=upper_bound(v4.begin(),v4.end(),a[i].b-a[i].a)-v4.begin();
if(s3!=m&&a[i].c<0)
{
s5=s3+1;
s2=st.get(1,0,m,0,s5);
st.upd2(1,0,m,s5,s2);
}
st.upd(1,0,m,0,s3,a[i].c);
}
for(auto x:v[i])
{
fe.upd(x,-b[x].c);
st.upd(1,0,m,x,m,b[x].c);
}
}
cout<<st.t[1].a+fe.get(m);
}
Compilation message
dishes.cpp:48:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
48 | main()
| ^~~~
dishes.cpp: In member function 'void IT::build(long long int, long long int, long long int)':
dishes.cpp:73:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
73 | int mid=l+r>>1;
| ~^~
dishes.cpp: In member function 'void IT::upd2(long long int, long long int, long long int, long long int, long long int)':
dishes.cpp:85:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
85 | int mid=l+r>>1;
| ~^~
dishes.cpp: In member function 'void IT::upd(long long int, long long int, long long int, long long int, long long int, long long int)':
dishes.cpp:100:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
100 | int mid=l+r>>1;
| ~^~
dishes.cpp: In member function 'long long int IT::get(long long int, long long int, long long int, long long int, long long int)':
dishes.cpp:110:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
110 | int mid=l+r>>1;
| ~^~
dishes.cpp: In member function 'void FEN::upd(long long int, long long int)':
dishes.cpp:120:13: warning: statement has no effect [-Wunused-value]
120 | for(x; x<=m; x+=x&-x)bit[x]+=y;
| ^
dishes.cpp: In member function 'long long int FEN::get(long long int)':
dishes.cpp:125:13: warning: statement has no effect [-Wunused-value]
125 | for(x; x; x-=x&-x) s+=bit[x];
| ^
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
189 ms |
51528 KB |
Output is correct |
2 |
Correct |
168 ms |
51524 KB |
Output is correct |
3 |
Correct |
96 ms |
50400 KB |
Output is correct |
4 |
Correct |
151 ms |
50760 KB |
Output is correct |
5 |
Correct |
6 ms |
31320 KB |
Output is correct |
6 |
Correct |
156 ms |
50604 KB |
Output is correct |
7 |
Correct |
56 ms |
45192 KB |
Output is correct |
8 |
Correct |
58 ms |
33228 KB |
Output is correct |
9 |
Correct |
105 ms |
50504 KB |
Output is correct |
10 |
Correct |
178 ms |
54160 KB |
Output is correct |
11 |
Correct |
78 ms |
50476 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
6 ms |
29272 KB |
Output is correct |
2 |
Correct |
6 ms |
27228 KB |
Output is correct |
3 |
Correct |
7 ms |
27308 KB |
Output is correct |
4 |
Correct |
7 ms |
27228 KB |
Output is correct |
5 |
Correct |
7 ms |
27228 KB |
Output is correct |
6 |
Correct |
8 ms |
29276 KB |
Output is correct |
7 |
Correct |
7 ms |
29276 KB |
Output is correct |
8 |
Correct |
8 ms |
31328 KB |
Output is correct |
9 |
Correct |
9 ms |
29276 KB |
Output is correct |
10 |
Correct |
8 ms |
31324 KB |
Output is correct |
11 |
Correct |
9 ms |
27228 KB |
Output is correct |
12 |
Correct |
7 ms |
29276 KB |
Output is correct |
13 |
Correct |
7 ms |
27224 KB |
Output is correct |
14 |
Correct |
7 ms |
27228 KB |
Output is correct |
15 |
Correct |
6 ms |
29260 KB |
Output is correct |
16 |
Correct |
7 ms |
29276 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
6 ms |
29272 KB |
Output is correct |
2 |
Correct |
6 ms |
27228 KB |
Output is correct |
3 |
Correct |
7 ms |
27308 KB |
Output is correct |
4 |
Correct |
7 ms |
27228 KB |
Output is correct |
5 |
Correct |
7 ms |
27228 KB |
Output is correct |
6 |
Correct |
8 ms |
29276 KB |
Output is correct |
7 |
Correct |
7 ms |
29276 KB |
Output is correct |
8 |
Correct |
8 ms |
31328 KB |
Output is correct |
9 |
Correct |
9 ms |
29276 KB |
Output is correct |
10 |
Correct |
8 ms |
31324 KB |
Output is correct |
11 |
Correct |
9 ms |
27228 KB |
Output is correct |
12 |
Correct |
7 ms |
29276 KB |
Output is correct |
13 |
Correct |
7 ms |
27224 KB |
Output is correct |
14 |
Correct |
7 ms |
27228 KB |
Output is correct |
15 |
Correct |
6 ms |
29260 KB |
Output is correct |
16 |
Correct |
7 ms |
29276 KB |
Output is correct |
17 |
Correct |
8 ms |
29276 KB |
Output is correct |
18 |
Correct |
8 ms |
29276 KB |
Output is correct |
19 |
Correct |
9 ms |
29276 KB |
Output is correct |
20 |
Correct |
7 ms |
29276 KB |
Output is correct |
21 |
Correct |
8 ms |
29272 KB |
Output is correct |
22 |
Correct |
9 ms |
27228 KB |
Output is correct |
23 |
Correct |
8 ms |
27228 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
6 ms |
29272 KB |
Output is correct |
2 |
Correct |
6 ms |
27228 KB |
Output is correct |
3 |
Correct |
7 ms |
27308 KB |
Output is correct |
4 |
Correct |
7 ms |
27228 KB |
Output is correct |
5 |
Correct |
7 ms |
27228 KB |
Output is correct |
6 |
Correct |
8 ms |
29276 KB |
Output is correct |
7 |
Correct |
7 ms |
29276 KB |
Output is correct |
8 |
Correct |
8 ms |
31328 KB |
Output is correct |
9 |
Correct |
9 ms |
29276 KB |
Output is correct |
10 |
Correct |
8 ms |
31324 KB |
Output is correct |
11 |
Correct |
9 ms |
27228 KB |
Output is correct |
12 |
Correct |
7 ms |
29276 KB |
Output is correct |
13 |
Correct |
7 ms |
27224 KB |
Output is correct |
14 |
Correct |
7 ms |
27228 KB |
Output is correct |
15 |
Correct |
6 ms |
29260 KB |
Output is correct |
16 |
Correct |
7 ms |
29276 KB |
Output is correct |
17 |
Correct |
8 ms |
29276 KB |
Output is correct |
18 |
Correct |
8 ms |
29276 KB |
Output is correct |
19 |
Correct |
9 ms |
29276 KB |
Output is correct |
20 |
Correct |
7 ms |
29276 KB |
Output is correct |
21 |
Correct |
8 ms |
29272 KB |
Output is correct |
22 |
Correct |
9 ms |
27228 KB |
Output is correct |
23 |
Correct |
8 ms |
27228 KB |
Output is correct |
24 |
Correct |
142 ms |
49632 KB |
Output is correct |
25 |
Correct |
145 ms |
50296 KB |
Output is correct |
26 |
Correct |
117 ms |
49736 KB |
Output is correct |
27 |
Correct |
167 ms |
54088 KB |
Output is correct |
28 |
Correct |
139 ms |
50248 KB |
Output is correct |
29 |
Correct |
92 ms |
50508 KB |
Output is correct |
30 |
Correct |
279 ms |
51956 KB |
Output is correct |
31 |
Correct |
77 ms |
45396 KB |
Output is correct |
32 |
Correct |
50 ms |
33544 KB |
Output is correct |
33 |
Correct |
244 ms |
50056 KB |
Output is correct |
34 |
Correct |
260 ms |
50668 KB |
Output is correct |
35 |
Correct |
283 ms |
52120 KB |
Output is correct |
36 |
Correct |
298 ms |
51788 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
6 ms |
29272 KB |
Output is correct |
2 |
Correct |
6 ms |
27228 KB |
Output is correct |
3 |
Correct |
7 ms |
27308 KB |
Output is correct |
4 |
Correct |
7 ms |
27228 KB |
Output is correct |
5 |
Correct |
7 ms |
27228 KB |
Output is correct |
6 |
Correct |
8 ms |
29276 KB |
Output is correct |
7 |
Correct |
7 ms |
29276 KB |
Output is correct |
8 |
Correct |
8 ms |
31328 KB |
Output is correct |
9 |
Correct |
9 ms |
29276 KB |
Output is correct |
10 |
Correct |
8 ms |
31324 KB |
Output is correct |
11 |
Correct |
9 ms |
27228 KB |
Output is correct |
12 |
Correct |
7 ms |
29276 KB |
Output is correct |
13 |
Correct |
7 ms |
27224 KB |
Output is correct |
14 |
Correct |
7 ms |
27228 KB |
Output is correct |
15 |
Correct |
6 ms |
29260 KB |
Output is correct |
16 |
Correct |
7 ms |
29276 KB |
Output is correct |
17 |
Correct |
8 ms |
29276 KB |
Output is correct |
18 |
Correct |
8 ms |
29276 KB |
Output is correct |
19 |
Correct |
9 ms |
29276 KB |
Output is correct |
20 |
Correct |
7 ms |
29276 KB |
Output is correct |
21 |
Correct |
8 ms |
29272 KB |
Output is correct |
22 |
Correct |
9 ms |
27228 KB |
Output is correct |
23 |
Correct |
8 ms |
27228 KB |
Output is correct |
24 |
Correct |
142 ms |
49632 KB |
Output is correct |
25 |
Correct |
145 ms |
50296 KB |
Output is correct |
26 |
Correct |
117 ms |
49736 KB |
Output is correct |
27 |
Correct |
167 ms |
54088 KB |
Output is correct |
28 |
Correct |
139 ms |
50248 KB |
Output is correct |
29 |
Correct |
92 ms |
50508 KB |
Output is correct |
30 |
Correct |
279 ms |
51956 KB |
Output is correct |
31 |
Correct |
77 ms |
45396 KB |
Output is correct |
32 |
Correct |
50 ms |
33544 KB |
Output is correct |
33 |
Correct |
244 ms |
50056 KB |
Output is correct |
34 |
Correct |
260 ms |
50668 KB |
Output is correct |
35 |
Correct |
283 ms |
52120 KB |
Output is correct |
36 |
Correct |
298 ms |
51788 KB |
Output is correct |
37 |
Correct |
132 ms |
49736 KB |
Output is correct |
38 |
Correct |
173 ms |
54212 KB |
Output is correct |
39 |
Correct |
178 ms |
54088 KB |
Output is correct |
40 |
Correct |
182 ms |
54024 KB |
Output is correct |
41 |
Correct |
6 ms |
29272 KB |
Output is correct |
42 |
Correct |
344 ms |
52084 KB |
Output is correct |
43 |
Correct |
204 ms |
49996 KB |
Output is correct |
44 |
Correct |
252 ms |
50504 KB |
Output is correct |
45 |
Correct |
278 ms |
52036 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
6 ms |
29272 KB |
Output is correct |
2 |
Correct |
6 ms |
27228 KB |
Output is correct |
3 |
Correct |
7 ms |
27308 KB |
Output is correct |
4 |
Correct |
7 ms |
27228 KB |
Output is correct |
5 |
Correct |
7 ms |
27228 KB |
Output is correct |
6 |
Correct |
8 ms |
29276 KB |
Output is correct |
7 |
Correct |
7 ms |
29276 KB |
Output is correct |
8 |
Correct |
8 ms |
31328 KB |
Output is correct |
9 |
Correct |
9 ms |
29276 KB |
Output is correct |
10 |
Correct |
8 ms |
31324 KB |
Output is correct |
11 |
Correct |
9 ms |
27228 KB |
Output is correct |
12 |
Correct |
7 ms |
29276 KB |
Output is correct |
13 |
Correct |
7 ms |
27224 KB |
Output is correct |
14 |
Correct |
7 ms |
27228 KB |
Output is correct |
15 |
Correct |
6 ms |
29260 KB |
Output is correct |
16 |
Correct |
7 ms |
29276 KB |
Output is correct |
17 |
Correct |
8 ms |
29276 KB |
Output is correct |
18 |
Correct |
8 ms |
29276 KB |
Output is correct |
19 |
Correct |
9 ms |
29276 KB |
Output is correct |
20 |
Correct |
7 ms |
29276 KB |
Output is correct |
21 |
Correct |
8 ms |
29272 KB |
Output is correct |
22 |
Correct |
9 ms |
27228 KB |
Output is correct |
23 |
Correct |
8 ms |
27228 KB |
Output is correct |
24 |
Correct |
142 ms |
49632 KB |
Output is correct |
25 |
Correct |
145 ms |
50296 KB |
Output is correct |
26 |
Correct |
117 ms |
49736 KB |
Output is correct |
27 |
Correct |
167 ms |
54088 KB |
Output is correct |
28 |
Correct |
139 ms |
50248 KB |
Output is correct |
29 |
Correct |
92 ms |
50508 KB |
Output is correct |
30 |
Correct |
279 ms |
51956 KB |
Output is correct |
31 |
Correct |
77 ms |
45396 KB |
Output is correct |
32 |
Correct |
50 ms |
33544 KB |
Output is correct |
33 |
Correct |
244 ms |
50056 KB |
Output is correct |
34 |
Correct |
260 ms |
50668 KB |
Output is correct |
35 |
Correct |
283 ms |
52120 KB |
Output is correct |
36 |
Correct |
298 ms |
51788 KB |
Output is correct |
37 |
Correct |
132 ms |
49736 KB |
Output is correct |
38 |
Correct |
173 ms |
54212 KB |
Output is correct |
39 |
Correct |
178 ms |
54088 KB |
Output is correct |
40 |
Correct |
182 ms |
54024 KB |
Output is correct |
41 |
Correct |
6 ms |
29272 KB |
Output is correct |
42 |
Correct |
344 ms |
52084 KB |
Output is correct |
43 |
Correct |
204 ms |
49996 KB |
Output is correct |
44 |
Correct |
252 ms |
50504 KB |
Output is correct |
45 |
Correct |
278 ms |
52036 KB |
Output is correct |
46 |
Correct |
601 ms |
135484 KB |
Output is correct |
47 |
Correct |
833 ms |
158340 KB |
Output is correct |
48 |
Correct |
972 ms |
158544 KB |
Output is correct |
49 |
Correct |
970 ms |
158504 KB |
Output is correct |
50 |
Correct |
2238 ms |
148100 KB |
Output is correct |
51 |
Correct |
1290 ms |
136984 KB |
Output is correct |
52 |
Correct |
1529 ms |
139044 KB |
Output is correct |
53 |
Correct |
1925 ms |
147596 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
189 ms |
51528 KB |
Output is correct |
2 |
Correct |
168 ms |
51524 KB |
Output is correct |
3 |
Correct |
96 ms |
50400 KB |
Output is correct |
4 |
Correct |
151 ms |
50760 KB |
Output is correct |
5 |
Correct |
6 ms |
31320 KB |
Output is correct |
6 |
Correct |
156 ms |
50604 KB |
Output is correct |
7 |
Correct |
56 ms |
45192 KB |
Output is correct |
8 |
Correct |
58 ms |
33228 KB |
Output is correct |
9 |
Correct |
105 ms |
50504 KB |
Output is correct |
10 |
Correct |
178 ms |
54160 KB |
Output is correct |
11 |
Correct |
78 ms |
50476 KB |
Output is correct |
12 |
Correct |
6 ms |
29272 KB |
Output is correct |
13 |
Correct |
6 ms |
27228 KB |
Output is correct |
14 |
Correct |
7 ms |
27308 KB |
Output is correct |
15 |
Correct |
7 ms |
27228 KB |
Output is correct |
16 |
Correct |
7 ms |
27228 KB |
Output is correct |
17 |
Correct |
8 ms |
29276 KB |
Output is correct |
18 |
Correct |
7 ms |
29276 KB |
Output is correct |
19 |
Correct |
8 ms |
31328 KB |
Output is correct |
20 |
Correct |
9 ms |
29276 KB |
Output is correct |
21 |
Correct |
8 ms |
31324 KB |
Output is correct |
22 |
Correct |
9 ms |
27228 KB |
Output is correct |
23 |
Correct |
7 ms |
29276 KB |
Output is correct |
24 |
Correct |
7 ms |
27224 KB |
Output is correct |
25 |
Correct |
7 ms |
27228 KB |
Output is correct |
26 |
Correct |
6 ms |
29260 KB |
Output is correct |
27 |
Correct |
7 ms |
29276 KB |
Output is correct |
28 |
Correct |
8 ms |
29276 KB |
Output is correct |
29 |
Correct |
8 ms |
29276 KB |
Output is correct |
30 |
Correct |
9 ms |
29276 KB |
Output is correct |
31 |
Correct |
7 ms |
29276 KB |
Output is correct |
32 |
Correct |
8 ms |
29272 KB |
Output is correct |
33 |
Correct |
9 ms |
27228 KB |
Output is correct |
34 |
Correct |
8 ms |
27228 KB |
Output is correct |
35 |
Correct |
142 ms |
49632 KB |
Output is correct |
36 |
Correct |
145 ms |
50296 KB |
Output is correct |
37 |
Correct |
117 ms |
49736 KB |
Output is correct |
38 |
Correct |
167 ms |
54088 KB |
Output is correct |
39 |
Correct |
139 ms |
50248 KB |
Output is correct |
40 |
Correct |
92 ms |
50508 KB |
Output is correct |
41 |
Correct |
279 ms |
51956 KB |
Output is correct |
42 |
Correct |
77 ms |
45396 KB |
Output is correct |
43 |
Correct |
50 ms |
33544 KB |
Output is correct |
44 |
Correct |
244 ms |
50056 KB |
Output is correct |
45 |
Correct |
260 ms |
50668 KB |
Output is correct |
46 |
Correct |
283 ms |
52120 KB |
Output is correct |
47 |
Correct |
298 ms |
51788 KB |
Output is correct |
48 |
Correct |
132 ms |
49736 KB |
Output is correct |
49 |
Correct |
173 ms |
54212 KB |
Output is correct |
50 |
Correct |
178 ms |
54088 KB |
Output is correct |
51 |
Correct |
182 ms |
54024 KB |
Output is correct |
52 |
Correct |
6 ms |
29272 KB |
Output is correct |
53 |
Correct |
344 ms |
52084 KB |
Output is correct |
54 |
Correct |
204 ms |
49996 KB |
Output is correct |
55 |
Correct |
252 ms |
50504 KB |
Output is correct |
56 |
Correct |
278 ms |
52036 KB |
Output is correct |
57 |
Correct |
165 ms |
49664 KB |
Output is correct |
58 |
Correct |
161 ms |
54036 KB |
Output is correct |
59 |
Correct |
203 ms |
54084 KB |
Output is correct |
60 |
Correct |
235 ms |
54092 KB |
Output is correct |
61 |
Correct |
319 ms |
52036 KB |
Output is correct |
62 |
Correct |
8 ms |
29272 KB |
Output is correct |
63 |
Correct |
351 ms |
52004 KB |
Output is correct |
64 |
Correct |
221 ms |
49988 KB |
Output is correct |
65 |
Correct |
302 ms |
50480 KB |
Output is correct |
66 |
Correct |
314 ms |
52036 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
189 ms |
51528 KB |
Output is correct |
2 |
Correct |
168 ms |
51524 KB |
Output is correct |
3 |
Correct |
96 ms |
50400 KB |
Output is correct |
4 |
Correct |
151 ms |
50760 KB |
Output is correct |
5 |
Correct |
6 ms |
31320 KB |
Output is correct |
6 |
Correct |
156 ms |
50604 KB |
Output is correct |
7 |
Correct |
56 ms |
45192 KB |
Output is correct |
8 |
Correct |
58 ms |
33228 KB |
Output is correct |
9 |
Correct |
105 ms |
50504 KB |
Output is correct |
10 |
Correct |
178 ms |
54160 KB |
Output is correct |
11 |
Correct |
78 ms |
50476 KB |
Output is correct |
12 |
Correct |
6 ms |
29272 KB |
Output is correct |
13 |
Correct |
6 ms |
27228 KB |
Output is correct |
14 |
Correct |
7 ms |
27308 KB |
Output is correct |
15 |
Correct |
7 ms |
27228 KB |
Output is correct |
16 |
Correct |
7 ms |
27228 KB |
Output is correct |
17 |
Correct |
8 ms |
29276 KB |
Output is correct |
18 |
Correct |
7 ms |
29276 KB |
Output is correct |
19 |
Correct |
8 ms |
31328 KB |
Output is correct |
20 |
Correct |
9 ms |
29276 KB |
Output is correct |
21 |
Correct |
8 ms |
31324 KB |
Output is correct |
22 |
Correct |
9 ms |
27228 KB |
Output is correct |
23 |
Correct |
7 ms |
29276 KB |
Output is correct |
24 |
Correct |
7 ms |
27224 KB |
Output is correct |
25 |
Correct |
7 ms |
27228 KB |
Output is correct |
26 |
Correct |
6 ms |
29260 KB |
Output is correct |
27 |
Correct |
7 ms |
29276 KB |
Output is correct |
28 |
Correct |
8 ms |
29276 KB |
Output is correct |
29 |
Correct |
8 ms |
29276 KB |
Output is correct |
30 |
Correct |
9 ms |
29276 KB |
Output is correct |
31 |
Correct |
7 ms |
29276 KB |
Output is correct |
32 |
Correct |
8 ms |
29272 KB |
Output is correct |
33 |
Correct |
9 ms |
27228 KB |
Output is correct |
34 |
Correct |
8 ms |
27228 KB |
Output is correct |
35 |
Correct |
142 ms |
49632 KB |
Output is correct |
36 |
Correct |
145 ms |
50296 KB |
Output is correct |
37 |
Correct |
117 ms |
49736 KB |
Output is correct |
38 |
Correct |
167 ms |
54088 KB |
Output is correct |
39 |
Correct |
139 ms |
50248 KB |
Output is correct |
40 |
Correct |
92 ms |
50508 KB |
Output is correct |
41 |
Correct |
279 ms |
51956 KB |
Output is correct |
42 |
Correct |
77 ms |
45396 KB |
Output is correct |
43 |
Correct |
50 ms |
33544 KB |
Output is correct |
44 |
Correct |
244 ms |
50056 KB |
Output is correct |
45 |
Correct |
260 ms |
50668 KB |
Output is correct |
46 |
Correct |
283 ms |
52120 KB |
Output is correct |
47 |
Correct |
298 ms |
51788 KB |
Output is correct |
48 |
Correct |
132 ms |
49736 KB |
Output is correct |
49 |
Correct |
173 ms |
54212 KB |
Output is correct |
50 |
Correct |
178 ms |
54088 KB |
Output is correct |
51 |
Correct |
182 ms |
54024 KB |
Output is correct |
52 |
Correct |
6 ms |
29272 KB |
Output is correct |
53 |
Correct |
344 ms |
52084 KB |
Output is correct |
54 |
Correct |
204 ms |
49996 KB |
Output is correct |
55 |
Correct |
252 ms |
50504 KB |
Output is correct |
56 |
Correct |
278 ms |
52036 KB |
Output is correct |
57 |
Correct |
601 ms |
135484 KB |
Output is correct |
58 |
Correct |
833 ms |
158340 KB |
Output is correct |
59 |
Correct |
972 ms |
158544 KB |
Output is correct |
60 |
Correct |
970 ms |
158504 KB |
Output is correct |
61 |
Correct |
2238 ms |
148100 KB |
Output is correct |
62 |
Correct |
1290 ms |
136984 KB |
Output is correct |
63 |
Correct |
1529 ms |
139044 KB |
Output is correct |
64 |
Correct |
1925 ms |
147596 KB |
Output is correct |
65 |
Correct |
165 ms |
49664 KB |
Output is correct |
66 |
Correct |
161 ms |
54036 KB |
Output is correct |
67 |
Correct |
203 ms |
54084 KB |
Output is correct |
68 |
Correct |
235 ms |
54092 KB |
Output is correct |
69 |
Correct |
319 ms |
52036 KB |
Output is correct |
70 |
Correct |
8 ms |
29272 KB |
Output is correct |
71 |
Correct |
351 ms |
52004 KB |
Output is correct |
72 |
Correct |
221 ms |
49988 KB |
Output is correct |
73 |
Correct |
302 ms |
50480 KB |
Output is correct |
74 |
Correct |
314 ms |
52036 KB |
Output is correct |
75 |
Correct |
864 ms |
135204 KB |
Output is correct |
76 |
Correct |
907 ms |
158496 KB |
Output is correct |
77 |
Correct |
1004 ms |
158476 KB |
Output is correct |
78 |
Correct |
1276 ms |
158480 KB |
Output is correct |
79 |
Correct |
2388 ms |
147980 KB |
Output is correct |
80 |
Correct |
1349 ms |
138076 KB |
Output is correct |
81 |
Correct |
1600 ms |
138348 KB |
Output is correct |
82 |
Correct |
2106 ms |
148084 KB |
Output is correct |
83 |
Correct |
2126 ms |
147236 KB |
Output is correct |