#include <bits/stdc++.h>
using namespace std;
#define DEBUG
#ifdef DEBUG
#define debug(...) printf(__VA_ARGS__);
#else
#define debug(...)
#endif
#define sf scanf
#define pf printf
#define fi first
#define se second
#define pb push_back
#define sz(x) (int)x.size()
#define mnto(x,y) x=min(x,(__typeof__(x))y)
#define mxto(x,y) x=max(x,(__typeof__(x))y)
#define INF 1023456789
#define LINF 1023456789123456789
#define all(x) x.begin(), x.end()
typedef long long ll;
typedef long double ld;
typedef pair<ll, int> ii;
typedef pair<ll, ll> pll;
typedef tuple<int, int, int> iii;
typedef tuple<int, int, int, int> iiii;
typedef vector<int> vi;
typedef vector<ii> vii;
typedef vector<pll> vll;
#define maxn 250005
struct node{
int s,e,m;
ll v,lz;
node *l,*r;
node(int _s,int _e){
s=_s;e=_e;m=(s+e)/2;v=0;lz=0;
if(s!=e)l=new node(s,m),r=new node(m+1,e);
}
void ppo(){
v+=lz;
if(s!=e)l->lz+=lz,r->lz+=lz;
lz=0;
}
void up(int x,int y,ll nv){
if(s==x&&e==y){
lz+=nv;return;
}
if(y<=m)l->up(x,y,nv);
else if(x>m)r->up(x,y,nv);
else l->up(x,m,nv),r->up(m+1,y,nv);
l->ppo();r->ppo();
v=min(l->v,r->v);
}
ll qry(int x,int y){
ppo();
if(s==x&&e==y)return v;
if(y<=m)return l->qry(x,y);
if(x>m)return r->qry(x,y);
return min(l->qry(x,m),r->qry(m+1,y));
}
}*root=new node(0,maxn),*tot=new node(0,maxn);
struct upd{
int pos;
ll val;
int tm,tp;
};
vector<upd> v;
int n,m,q,t,l,r,c,id[maxn],ans[maxn];
vii qry[maxn];
ll k,ft[maxn];
void up(int x,ll v){
while(x<maxn)ft[x]+=v,x+=x&-x;
}
ll query(int x){
ll res=0;
while(x)res+=ft[x],x-=x&-x;
return res;
}
int desc(ll v){
int cur=0;
for(int u=(1<<17);u!=0;u>>=1){
if(cur+u<maxn&&ft[cur+u]<=v){
cur+=u;
v-=ft[cur];
}
}
return cur;
}
int main(){
sf("%d%d%d",&n,&m,&q);
for(int i=1;i<=q;++i){
sf("%d",&t);
if(t==1){
sf("%d%d%d%lld",&l,&r,&c,&k);
v.pb({l,k,i,0});
v.pb({r+1,-k,i,0});
id[i]=c;
}
if(t==2){
sf("%d%d%lld",&l,&r,&k);
v.pb({l,-k,i,1});
v.pb({r+1,k,i,1});
}
if(t==3){
sf("%d%lld",&l,&k);
qry[l].pb({k,i});
}
}
memset(ans,-1,sizeof ans);
sort(all(v),[&](upd a,upd b){ return a.pos>b.pos; });
for(int i=1;i<=n;++i){
while(!v.empty()&&v.back().pos==i){
root->up(v.back().tm,maxn,v.back().val);
if(v.back().tp==0)up(v.back().tm,v.back().val);
v.pop_back();
}
for(ii pr:qry[i]){
ll num=root->qry(pr.se,pr.se)-root->qry(0,pr.se);
//current size
if(num<pr.fi)ans[pr.se]=0;
else{
ll tot=query(pr.se);
pr.fi+=tot-num;//how many were removed
int pos=desc(pr.fi-1);
ans[pr.se]=id[pos+1];
}
}
}
for(int i=1;i<=q;++i)if(ans[i]!=-1)pf("%d\n",ans[i]);
}
/*
3 5 7
1 2 3 5 2
1 1 2 2 4
3 2 3
2 1 3 3
3 1 2
1 2 3 4 2
3 3 2
3 4 7
1 1 2 1 1
1 1 3 4 1
2 2 3 1
2 1 3 1
1 1 2 2 1
3 1 1
3 3 2
10 5 100
1 1 1 1 1
2 1 1 2
1 1 1 1 1
2 1 1 2
1 1 1 1 1
2 1 1 2
3 1 1
1 1 1 5 5
1 1 1 5 5
2 1 1 3
3 1 1
*/
Compilation message
foodcourt.cpp: In function 'int main()':
foodcourt.cpp:97:4: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
97 | sf("%d%d%d",&n,&m,&q);
| ^
foodcourt.cpp:99:5: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
99 | sf("%d",&t);
| ^
foodcourt.cpp:101:6: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
101 | sf("%d%d%d%lld",&l,&r,&c,&k);
| ^
foodcourt.cpp:107:6: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
107 | sf("%d%d%lld",&l,&r,&k);
| ^
foodcourt.cpp:112:6: warning: ignoring return value of 'int scanf(const char*, ...)' declared with attribute 'warn_unused_result' [-Wunused-result]
112 | sf("%d%lld",&l,&k);
| ^
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
56 ms |
69956 KB |
Output is correct |
2 |
Correct |
59 ms |
69916 KB |
Output is correct |
3 |
Correct |
67 ms |
69924 KB |
Output is correct |
4 |
Correct |
57 ms |
70080 KB |
Output is correct |
5 |
Correct |
57 ms |
69904 KB |
Output is correct |
6 |
Correct |
57 ms |
69860 KB |
Output is correct |
7 |
Correct |
60 ms |
69980 KB |
Output is correct |
8 |
Correct |
71 ms |
69896 KB |
Output is correct |
9 |
Correct |
59 ms |
69976 KB |
Output is correct |
10 |
Correct |
58 ms |
69956 KB |
Output is correct |
11 |
Correct |
58 ms |
69928 KB |
Output is correct |
12 |
Correct |
59 ms |
69956 KB |
Output is correct |
13 |
Correct |
58 ms |
69864 KB |
Output is correct |
14 |
Correct |
58 ms |
69996 KB |
Output is correct |
15 |
Correct |
66 ms |
69920 KB |
Output is correct |
16 |
Correct |
57 ms |
69948 KB |
Output is correct |
17 |
Correct |
57 ms |
69940 KB |
Output is correct |
18 |
Correct |
59 ms |
69996 KB |
Output is correct |
19 |
Correct |
69 ms |
69960 KB |
Output is correct |
20 |
Correct |
66 ms |
70072 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
56 ms |
69956 KB |
Output is correct |
2 |
Correct |
59 ms |
69916 KB |
Output is correct |
3 |
Correct |
67 ms |
69924 KB |
Output is correct |
4 |
Correct |
57 ms |
70080 KB |
Output is correct |
5 |
Correct |
57 ms |
69904 KB |
Output is correct |
6 |
Correct |
57 ms |
69860 KB |
Output is correct |
7 |
Correct |
60 ms |
69980 KB |
Output is correct |
8 |
Correct |
71 ms |
69896 KB |
Output is correct |
9 |
Correct |
59 ms |
69976 KB |
Output is correct |
10 |
Correct |
58 ms |
69956 KB |
Output is correct |
11 |
Correct |
58 ms |
69928 KB |
Output is correct |
12 |
Correct |
59 ms |
69956 KB |
Output is correct |
13 |
Correct |
58 ms |
69864 KB |
Output is correct |
14 |
Correct |
58 ms |
69996 KB |
Output is correct |
15 |
Correct |
66 ms |
69920 KB |
Output is correct |
16 |
Correct |
57 ms |
69948 KB |
Output is correct |
17 |
Correct |
57 ms |
69940 KB |
Output is correct |
18 |
Correct |
59 ms |
69996 KB |
Output is correct |
19 |
Correct |
69 ms |
69960 KB |
Output is correct |
20 |
Correct |
66 ms |
70072 KB |
Output is correct |
21 |
Correct |
56 ms |
70008 KB |
Output is correct |
22 |
Correct |
63 ms |
69956 KB |
Output is correct |
23 |
Correct |
58 ms |
69976 KB |
Output is correct |
24 |
Correct |
58 ms |
69956 KB |
Output is correct |
25 |
Correct |
70 ms |
70020 KB |
Output is correct |
26 |
Correct |
58 ms |
69976 KB |
Output is correct |
27 |
Correct |
63 ms |
69896 KB |
Output is correct |
28 |
Correct |
57 ms |
70004 KB |
Output is correct |
29 |
Correct |
57 ms |
69916 KB |
Output is correct |
30 |
Correct |
71 ms |
69976 KB |
Output is correct |
31 |
Correct |
58 ms |
69960 KB |
Output is correct |
32 |
Correct |
59 ms |
69996 KB |
Output is correct |
33 |
Correct |
56 ms |
70004 KB |
Output is correct |
34 |
Correct |
56 ms |
69964 KB |
Output is correct |
35 |
Correct |
59 ms |
69956 KB |
Output is correct |
36 |
Correct |
60 ms |
69956 KB |
Output is correct |
37 |
Correct |
58 ms |
69912 KB |
Output is correct |
38 |
Correct |
56 ms |
69956 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
173 ms |
74416 KB |
Output is correct |
2 |
Correct |
181 ms |
74572 KB |
Output is correct |
3 |
Correct |
176 ms |
74376 KB |
Output is correct |
4 |
Correct |
202 ms |
74412 KB |
Output is correct |
5 |
Correct |
177 ms |
74568 KB |
Output is correct |
6 |
Correct |
178 ms |
74472 KB |
Output is correct |
7 |
Correct |
126 ms |
73936 KB |
Output is correct |
8 |
Correct |
133 ms |
73824 KB |
Output is correct |
9 |
Correct |
175 ms |
74248 KB |
Output is correct |
10 |
Correct |
184 ms |
74504 KB |
Output is correct |
11 |
Correct |
200 ms |
74492 KB |
Output is correct |
12 |
Correct |
174 ms |
74592 KB |
Output is correct |
13 |
Correct |
162 ms |
73964 KB |
Output is correct |
14 |
Correct |
169 ms |
74320 KB |
Output is correct |
15 |
Correct |
175 ms |
74664 KB |
Output is correct |
16 |
Correct |
183 ms |
74840 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
685 ms |
88628 KB |
Output is correct |
2 |
Correct |
536 ms |
83872 KB |
Output is correct |
3 |
Correct |
794 ms |
89048 KB |
Output is correct |
4 |
Correct |
575 ms |
87480 KB |
Output is correct |
5 |
Correct |
627 ms |
87560 KB |
Output is correct |
6 |
Correct |
879 ms |
89540 KB |
Output is correct |
7 |
Correct |
352 ms |
88172 KB |
Output is correct |
8 |
Correct |
349 ms |
87084 KB |
Output is correct |
9 |
Correct |
887 ms |
88364 KB |
Output is correct |
10 |
Correct |
797 ms |
88460 KB |
Output is correct |
11 |
Correct |
732 ms |
88044 KB |
Output is correct |
12 |
Correct |
807 ms |
89496 KB |
Output is correct |
13 |
Correct |
737 ms |
88180 KB |
Output is correct |
14 |
Correct |
751 ms |
89588 KB |
Output is correct |
15 |
Correct |
826 ms |
89356 KB |
Output is correct |
16 |
Correct |
741 ms |
89392 KB |
Output is correct |
17 |
Correct |
753 ms |
89444 KB |
Output is correct |
18 |
Correct |
810 ms |
88716 KB |
Output is correct |
19 |
Correct |
844 ms |
89428 KB |
Output is correct |
20 |
Correct |
770 ms |
88856 KB |
Output is correct |
21 |
Correct |
742 ms |
89404 KB |
Output is correct |
22 |
Correct |
754 ms |
89364 KB |
Output is correct |
23 |
Correct |
728 ms |
89388 KB |
Output is correct |
24 |
Correct |
813 ms |
89340 KB |
Output is correct |
25 |
Correct |
727 ms |
88384 KB |
Output is correct |
26 |
Correct |
717 ms |
88920 KB |
Output is correct |
27 |
Correct |
549 ms |
89636 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
56 ms |
69956 KB |
Output is correct |
2 |
Correct |
59 ms |
69916 KB |
Output is correct |
3 |
Correct |
67 ms |
69924 KB |
Output is correct |
4 |
Correct |
57 ms |
70080 KB |
Output is correct |
5 |
Correct |
57 ms |
69904 KB |
Output is correct |
6 |
Correct |
57 ms |
69860 KB |
Output is correct |
7 |
Correct |
60 ms |
69980 KB |
Output is correct |
8 |
Correct |
71 ms |
69896 KB |
Output is correct |
9 |
Correct |
59 ms |
69976 KB |
Output is correct |
10 |
Correct |
58 ms |
69956 KB |
Output is correct |
11 |
Correct |
58 ms |
69928 KB |
Output is correct |
12 |
Correct |
59 ms |
69956 KB |
Output is correct |
13 |
Correct |
58 ms |
69864 KB |
Output is correct |
14 |
Correct |
58 ms |
69996 KB |
Output is correct |
15 |
Correct |
66 ms |
69920 KB |
Output is correct |
16 |
Correct |
57 ms |
69948 KB |
Output is correct |
17 |
Correct |
57 ms |
69940 KB |
Output is correct |
18 |
Correct |
59 ms |
69996 KB |
Output is correct |
19 |
Correct |
69 ms |
69960 KB |
Output is correct |
20 |
Correct |
66 ms |
70072 KB |
Output is correct |
21 |
Correct |
173 ms |
74416 KB |
Output is correct |
22 |
Correct |
181 ms |
74572 KB |
Output is correct |
23 |
Correct |
176 ms |
74376 KB |
Output is correct |
24 |
Correct |
202 ms |
74412 KB |
Output is correct |
25 |
Correct |
177 ms |
74568 KB |
Output is correct |
26 |
Correct |
178 ms |
74472 KB |
Output is correct |
27 |
Correct |
126 ms |
73936 KB |
Output is correct |
28 |
Correct |
133 ms |
73824 KB |
Output is correct |
29 |
Correct |
175 ms |
74248 KB |
Output is correct |
30 |
Correct |
184 ms |
74504 KB |
Output is correct |
31 |
Correct |
200 ms |
74492 KB |
Output is correct |
32 |
Correct |
174 ms |
74592 KB |
Output is correct |
33 |
Correct |
162 ms |
73964 KB |
Output is correct |
34 |
Correct |
169 ms |
74320 KB |
Output is correct |
35 |
Correct |
175 ms |
74664 KB |
Output is correct |
36 |
Correct |
183 ms |
74840 KB |
Output is correct |
37 |
Correct |
165 ms |
73824 KB |
Output is correct |
38 |
Correct |
181 ms |
73584 KB |
Output is correct |
39 |
Correct |
122 ms |
73244 KB |
Output is correct |
40 |
Correct |
136 ms |
73544 KB |
Output is correct |
41 |
Correct |
187 ms |
74048 KB |
Output is correct |
42 |
Correct |
190 ms |
74412 KB |
Output is correct |
43 |
Correct |
212 ms |
74384 KB |
Output is correct |
44 |
Correct |
187 ms |
74208 KB |
Output is correct |
45 |
Correct |
185 ms |
74400 KB |
Output is correct |
46 |
Correct |
187 ms |
74560 KB |
Output is correct |
47 |
Correct |
130 ms |
74108 KB |
Output is correct |
48 |
Correct |
178 ms |
74172 KB |
Output is correct |
49 |
Correct |
162 ms |
73076 KB |
Output is correct |
50 |
Correct |
191 ms |
73752 KB |
Output is correct |
51 |
Correct |
177 ms |
74448 KB |
Output is correct |
52 |
Correct |
202 ms |
74448 KB |
Output is correct |
53 |
Correct |
154 ms |
73668 KB |
Output is correct |
54 |
Correct |
171 ms |
74684 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
160 ms |
74232 KB |
Output is correct |
2 |
Correct |
175 ms |
74616 KB |
Output is correct |
3 |
Correct |
201 ms |
74764 KB |
Output is correct |
4 |
Correct |
135 ms |
73276 KB |
Output is correct |
5 |
Correct |
155 ms |
74060 KB |
Output is correct |
6 |
Correct |
197 ms |
74752 KB |
Output is correct |
7 |
Correct |
121 ms |
73564 KB |
Output is correct |
8 |
Correct |
118 ms |
73548 KB |
Output is correct |
9 |
Correct |
143 ms |
74664 KB |
Output is correct |
10 |
Correct |
141 ms |
73176 KB |
Output is correct |
11 |
Correct |
173 ms |
74724 KB |
Output is correct |
12 |
Correct |
179 ms |
74720 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
56 ms |
69956 KB |
Output is correct |
2 |
Correct |
59 ms |
69916 KB |
Output is correct |
3 |
Correct |
67 ms |
69924 KB |
Output is correct |
4 |
Correct |
57 ms |
70080 KB |
Output is correct |
5 |
Correct |
57 ms |
69904 KB |
Output is correct |
6 |
Correct |
57 ms |
69860 KB |
Output is correct |
7 |
Correct |
60 ms |
69980 KB |
Output is correct |
8 |
Correct |
71 ms |
69896 KB |
Output is correct |
9 |
Correct |
59 ms |
69976 KB |
Output is correct |
10 |
Correct |
58 ms |
69956 KB |
Output is correct |
11 |
Correct |
58 ms |
69928 KB |
Output is correct |
12 |
Correct |
59 ms |
69956 KB |
Output is correct |
13 |
Correct |
58 ms |
69864 KB |
Output is correct |
14 |
Correct |
58 ms |
69996 KB |
Output is correct |
15 |
Correct |
66 ms |
69920 KB |
Output is correct |
16 |
Correct |
57 ms |
69948 KB |
Output is correct |
17 |
Correct |
57 ms |
69940 KB |
Output is correct |
18 |
Correct |
59 ms |
69996 KB |
Output is correct |
19 |
Correct |
69 ms |
69960 KB |
Output is correct |
20 |
Correct |
66 ms |
70072 KB |
Output is correct |
21 |
Correct |
56 ms |
70008 KB |
Output is correct |
22 |
Correct |
63 ms |
69956 KB |
Output is correct |
23 |
Correct |
58 ms |
69976 KB |
Output is correct |
24 |
Correct |
58 ms |
69956 KB |
Output is correct |
25 |
Correct |
70 ms |
70020 KB |
Output is correct |
26 |
Correct |
58 ms |
69976 KB |
Output is correct |
27 |
Correct |
63 ms |
69896 KB |
Output is correct |
28 |
Correct |
57 ms |
70004 KB |
Output is correct |
29 |
Correct |
57 ms |
69916 KB |
Output is correct |
30 |
Correct |
71 ms |
69976 KB |
Output is correct |
31 |
Correct |
58 ms |
69960 KB |
Output is correct |
32 |
Correct |
59 ms |
69996 KB |
Output is correct |
33 |
Correct |
56 ms |
70004 KB |
Output is correct |
34 |
Correct |
56 ms |
69964 KB |
Output is correct |
35 |
Correct |
59 ms |
69956 KB |
Output is correct |
36 |
Correct |
60 ms |
69956 KB |
Output is correct |
37 |
Correct |
58 ms |
69912 KB |
Output is correct |
38 |
Correct |
56 ms |
69956 KB |
Output is correct |
39 |
Correct |
173 ms |
74416 KB |
Output is correct |
40 |
Correct |
181 ms |
74572 KB |
Output is correct |
41 |
Correct |
176 ms |
74376 KB |
Output is correct |
42 |
Correct |
202 ms |
74412 KB |
Output is correct |
43 |
Correct |
177 ms |
74568 KB |
Output is correct |
44 |
Correct |
178 ms |
74472 KB |
Output is correct |
45 |
Correct |
126 ms |
73936 KB |
Output is correct |
46 |
Correct |
133 ms |
73824 KB |
Output is correct |
47 |
Correct |
175 ms |
74248 KB |
Output is correct |
48 |
Correct |
184 ms |
74504 KB |
Output is correct |
49 |
Correct |
200 ms |
74492 KB |
Output is correct |
50 |
Correct |
174 ms |
74592 KB |
Output is correct |
51 |
Correct |
162 ms |
73964 KB |
Output is correct |
52 |
Correct |
169 ms |
74320 KB |
Output is correct |
53 |
Correct |
175 ms |
74664 KB |
Output is correct |
54 |
Correct |
183 ms |
74840 KB |
Output is correct |
55 |
Correct |
165 ms |
73824 KB |
Output is correct |
56 |
Correct |
181 ms |
73584 KB |
Output is correct |
57 |
Correct |
122 ms |
73244 KB |
Output is correct |
58 |
Correct |
136 ms |
73544 KB |
Output is correct |
59 |
Correct |
187 ms |
74048 KB |
Output is correct |
60 |
Correct |
190 ms |
74412 KB |
Output is correct |
61 |
Correct |
212 ms |
74384 KB |
Output is correct |
62 |
Correct |
187 ms |
74208 KB |
Output is correct |
63 |
Correct |
185 ms |
74400 KB |
Output is correct |
64 |
Correct |
187 ms |
74560 KB |
Output is correct |
65 |
Correct |
130 ms |
74108 KB |
Output is correct |
66 |
Correct |
178 ms |
74172 KB |
Output is correct |
67 |
Correct |
162 ms |
73076 KB |
Output is correct |
68 |
Correct |
191 ms |
73752 KB |
Output is correct |
69 |
Correct |
177 ms |
74448 KB |
Output is correct |
70 |
Correct |
202 ms |
74448 KB |
Output is correct |
71 |
Correct |
154 ms |
73668 KB |
Output is correct |
72 |
Correct |
171 ms |
74684 KB |
Output is correct |
73 |
Correct |
160 ms |
74232 KB |
Output is correct |
74 |
Correct |
175 ms |
74616 KB |
Output is correct |
75 |
Correct |
201 ms |
74764 KB |
Output is correct |
76 |
Correct |
135 ms |
73276 KB |
Output is correct |
77 |
Correct |
155 ms |
74060 KB |
Output is correct |
78 |
Correct |
197 ms |
74752 KB |
Output is correct |
79 |
Correct |
121 ms |
73564 KB |
Output is correct |
80 |
Correct |
118 ms |
73548 KB |
Output is correct |
81 |
Correct |
143 ms |
74664 KB |
Output is correct |
82 |
Correct |
141 ms |
73176 KB |
Output is correct |
83 |
Correct |
173 ms |
74724 KB |
Output is correct |
84 |
Correct |
179 ms |
74720 KB |
Output is correct |
85 |
Correct |
194 ms |
74328 KB |
Output is correct |
86 |
Correct |
234 ms |
74848 KB |
Output is correct |
87 |
Correct |
170 ms |
74336 KB |
Output is correct |
88 |
Correct |
200 ms |
75004 KB |
Output is correct |
89 |
Correct |
142 ms |
73044 KB |
Output is correct |
90 |
Correct |
203 ms |
74940 KB |
Output is correct |
91 |
Correct |
159 ms |
74104 KB |
Output is correct |
92 |
Correct |
154 ms |
73796 KB |
Output is correct |
93 |
Correct |
212 ms |
74884 KB |
Output is correct |
94 |
Correct |
220 ms |
74780 KB |
Output is correct |
95 |
Correct |
182 ms |
74872 KB |
Output is correct |
96 |
Correct |
212 ms |
74904 KB |
Output is correct |
97 |
Correct |
214 ms |
74952 KB |
Output is correct |
98 |
Correct |
172 ms |
74188 KB |
Output is correct |
99 |
Correct |
136 ms |
74644 KB |
Output is correct |
100 |
Correct |
153 ms |
73932 KB |
Output is correct |
101 |
Correct |
181 ms |
74716 KB |
Output is correct |
102 |
Correct |
165 ms |
75044 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
56 ms |
69956 KB |
Output is correct |
2 |
Correct |
59 ms |
69916 KB |
Output is correct |
3 |
Correct |
67 ms |
69924 KB |
Output is correct |
4 |
Correct |
57 ms |
70080 KB |
Output is correct |
5 |
Correct |
57 ms |
69904 KB |
Output is correct |
6 |
Correct |
57 ms |
69860 KB |
Output is correct |
7 |
Correct |
60 ms |
69980 KB |
Output is correct |
8 |
Correct |
71 ms |
69896 KB |
Output is correct |
9 |
Correct |
59 ms |
69976 KB |
Output is correct |
10 |
Correct |
58 ms |
69956 KB |
Output is correct |
11 |
Correct |
58 ms |
69928 KB |
Output is correct |
12 |
Correct |
59 ms |
69956 KB |
Output is correct |
13 |
Correct |
58 ms |
69864 KB |
Output is correct |
14 |
Correct |
58 ms |
69996 KB |
Output is correct |
15 |
Correct |
66 ms |
69920 KB |
Output is correct |
16 |
Correct |
57 ms |
69948 KB |
Output is correct |
17 |
Correct |
57 ms |
69940 KB |
Output is correct |
18 |
Correct |
59 ms |
69996 KB |
Output is correct |
19 |
Correct |
69 ms |
69960 KB |
Output is correct |
20 |
Correct |
66 ms |
70072 KB |
Output is correct |
21 |
Correct |
56 ms |
70008 KB |
Output is correct |
22 |
Correct |
63 ms |
69956 KB |
Output is correct |
23 |
Correct |
58 ms |
69976 KB |
Output is correct |
24 |
Correct |
58 ms |
69956 KB |
Output is correct |
25 |
Correct |
70 ms |
70020 KB |
Output is correct |
26 |
Correct |
58 ms |
69976 KB |
Output is correct |
27 |
Correct |
63 ms |
69896 KB |
Output is correct |
28 |
Correct |
57 ms |
70004 KB |
Output is correct |
29 |
Correct |
57 ms |
69916 KB |
Output is correct |
30 |
Correct |
71 ms |
69976 KB |
Output is correct |
31 |
Correct |
58 ms |
69960 KB |
Output is correct |
32 |
Correct |
59 ms |
69996 KB |
Output is correct |
33 |
Correct |
56 ms |
70004 KB |
Output is correct |
34 |
Correct |
56 ms |
69964 KB |
Output is correct |
35 |
Correct |
59 ms |
69956 KB |
Output is correct |
36 |
Correct |
60 ms |
69956 KB |
Output is correct |
37 |
Correct |
58 ms |
69912 KB |
Output is correct |
38 |
Correct |
56 ms |
69956 KB |
Output is correct |
39 |
Correct |
173 ms |
74416 KB |
Output is correct |
40 |
Correct |
181 ms |
74572 KB |
Output is correct |
41 |
Correct |
176 ms |
74376 KB |
Output is correct |
42 |
Correct |
202 ms |
74412 KB |
Output is correct |
43 |
Correct |
177 ms |
74568 KB |
Output is correct |
44 |
Correct |
178 ms |
74472 KB |
Output is correct |
45 |
Correct |
126 ms |
73936 KB |
Output is correct |
46 |
Correct |
133 ms |
73824 KB |
Output is correct |
47 |
Correct |
175 ms |
74248 KB |
Output is correct |
48 |
Correct |
184 ms |
74504 KB |
Output is correct |
49 |
Correct |
200 ms |
74492 KB |
Output is correct |
50 |
Correct |
174 ms |
74592 KB |
Output is correct |
51 |
Correct |
162 ms |
73964 KB |
Output is correct |
52 |
Correct |
169 ms |
74320 KB |
Output is correct |
53 |
Correct |
175 ms |
74664 KB |
Output is correct |
54 |
Correct |
183 ms |
74840 KB |
Output is correct |
55 |
Correct |
685 ms |
88628 KB |
Output is correct |
56 |
Correct |
536 ms |
83872 KB |
Output is correct |
57 |
Correct |
794 ms |
89048 KB |
Output is correct |
58 |
Correct |
575 ms |
87480 KB |
Output is correct |
59 |
Correct |
627 ms |
87560 KB |
Output is correct |
60 |
Correct |
879 ms |
89540 KB |
Output is correct |
61 |
Correct |
352 ms |
88172 KB |
Output is correct |
62 |
Correct |
349 ms |
87084 KB |
Output is correct |
63 |
Correct |
887 ms |
88364 KB |
Output is correct |
64 |
Correct |
797 ms |
88460 KB |
Output is correct |
65 |
Correct |
732 ms |
88044 KB |
Output is correct |
66 |
Correct |
807 ms |
89496 KB |
Output is correct |
67 |
Correct |
737 ms |
88180 KB |
Output is correct |
68 |
Correct |
751 ms |
89588 KB |
Output is correct |
69 |
Correct |
826 ms |
89356 KB |
Output is correct |
70 |
Correct |
741 ms |
89392 KB |
Output is correct |
71 |
Correct |
753 ms |
89444 KB |
Output is correct |
72 |
Correct |
810 ms |
88716 KB |
Output is correct |
73 |
Correct |
844 ms |
89428 KB |
Output is correct |
74 |
Correct |
770 ms |
88856 KB |
Output is correct |
75 |
Correct |
742 ms |
89404 KB |
Output is correct |
76 |
Correct |
754 ms |
89364 KB |
Output is correct |
77 |
Correct |
728 ms |
89388 KB |
Output is correct |
78 |
Correct |
813 ms |
89340 KB |
Output is correct |
79 |
Correct |
727 ms |
88384 KB |
Output is correct |
80 |
Correct |
717 ms |
88920 KB |
Output is correct |
81 |
Correct |
549 ms |
89636 KB |
Output is correct |
82 |
Correct |
165 ms |
73824 KB |
Output is correct |
83 |
Correct |
181 ms |
73584 KB |
Output is correct |
84 |
Correct |
122 ms |
73244 KB |
Output is correct |
85 |
Correct |
136 ms |
73544 KB |
Output is correct |
86 |
Correct |
187 ms |
74048 KB |
Output is correct |
87 |
Correct |
190 ms |
74412 KB |
Output is correct |
88 |
Correct |
212 ms |
74384 KB |
Output is correct |
89 |
Correct |
187 ms |
74208 KB |
Output is correct |
90 |
Correct |
185 ms |
74400 KB |
Output is correct |
91 |
Correct |
187 ms |
74560 KB |
Output is correct |
92 |
Correct |
130 ms |
74108 KB |
Output is correct |
93 |
Correct |
178 ms |
74172 KB |
Output is correct |
94 |
Correct |
162 ms |
73076 KB |
Output is correct |
95 |
Correct |
191 ms |
73752 KB |
Output is correct |
96 |
Correct |
177 ms |
74448 KB |
Output is correct |
97 |
Correct |
202 ms |
74448 KB |
Output is correct |
98 |
Correct |
154 ms |
73668 KB |
Output is correct |
99 |
Correct |
171 ms |
74684 KB |
Output is correct |
100 |
Correct |
160 ms |
74232 KB |
Output is correct |
101 |
Correct |
175 ms |
74616 KB |
Output is correct |
102 |
Correct |
201 ms |
74764 KB |
Output is correct |
103 |
Correct |
135 ms |
73276 KB |
Output is correct |
104 |
Correct |
155 ms |
74060 KB |
Output is correct |
105 |
Correct |
197 ms |
74752 KB |
Output is correct |
106 |
Correct |
121 ms |
73564 KB |
Output is correct |
107 |
Correct |
118 ms |
73548 KB |
Output is correct |
108 |
Correct |
143 ms |
74664 KB |
Output is correct |
109 |
Correct |
141 ms |
73176 KB |
Output is correct |
110 |
Correct |
173 ms |
74724 KB |
Output is correct |
111 |
Correct |
179 ms |
74720 KB |
Output is correct |
112 |
Correct |
194 ms |
74328 KB |
Output is correct |
113 |
Correct |
234 ms |
74848 KB |
Output is correct |
114 |
Correct |
170 ms |
74336 KB |
Output is correct |
115 |
Correct |
200 ms |
75004 KB |
Output is correct |
116 |
Correct |
142 ms |
73044 KB |
Output is correct |
117 |
Correct |
203 ms |
74940 KB |
Output is correct |
118 |
Correct |
159 ms |
74104 KB |
Output is correct |
119 |
Correct |
154 ms |
73796 KB |
Output is correct |
120 |
Correct |
212 ms |
74884 KB |
Output is correct |
121 |
Correct |
220 ms |
74780 KB |
Output is correct |
122 |
Correct |
182 ms |
74872 KB |
Output is correct |
123 |
Correct |
212 ms |
74904 KB |
Output is correct |
124 |
Correct |
214 ms |
74952 KB |
Output is correct |
125 |
Correct |
172 ms |
74188 KB |
Output is correct |
126 |
Correct |
136 ms |
74644 KB |
Output is correct |
127 |
Correct |
153 ms |
73932 KB |
Output is correct |
128 |
Correct |
181 ms |
74716 KB |
Output is correct |
129 |
Correct |
165 ms |
75044 KB |
Output is correct |
130 |
Correct |
780 ms |
89612 KB |
Output is correct |
131 |
Correct |
525 ms |
84164 KB |
Output is correct |
132 |
Correct |
760 ms |
89584 KB |
Output is correct |
133 |
Correct |
842 ms |
89452 KB |
Output is correct |
134 |
Correct |
695 ms |
88000 KB |
Output is correct |
135 |
Correct |
804 ms |
90360 KB |
Output is correct |
136 |
Correct |
709 ms |
89312 KB |
Output is correct |
137 |
Correct |
699 ms |
89312 KB |
Output is correct |
138 |
Correct |
821 ms |
88736 KB |
Output is correct |
139 |
Correct |
751 ms |
90212 KB |
Output is correct |
140 |
Correct |
749 ms |
89136 KB |
Output is correct |
141 |
Correct |
732 ms |
90068 KB |
Output is correct |
142 |
Correct |
745 ms |
90060 KB |
Output is correct |
143 |
Correct |
748 ms |
90004 KB |
Output is correct |
144 |
Correct |
750 ms |
89392 KB |
Output is correct |
145 |
Correct |
737 ms |
90096 KB |
Output is correct |
146 |
Correct |
727 ms |
89772 KB |
Output is correct |
147 |
Correct |
753 ms |
90028 KB |
Output is correct |
148 |
Correct |
787 ms |
90152 KB |
Output is correct |
149 |
Correct |
760 ms |
90080 KB |
Output is correct |
150 |
Correct |
428 ms |
88960 KB |
Output is correct |
151 |
Correct |
702 ms |
89364 KB |
Output is correct |
152 |
Correct |
767 ms |
89384 KB |
Output is correct |
153 |
Correct |
544 ms |
90416 KB |
Output is correct |