#pragma GCC optimize("Ofast,unroll-loops")
#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;
#define getchar_unlocked getchar
inline int scan()
{
char c = getchar_unlocked();
int x = 0;
while(c<'0'||c>'9')
{
c=getchar_unlocked();
}
while(c>='0'&&c<='9')
{
x=(x<<1)+(x<<3)+c-'0';
c=getchar_unlocked();
}
return x;
}
void phongbeo();
const int inf=1e9;
const int mod2=1e9+9;
const int mod1=998244353;
struct icd
{
long double a;
int 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;
};
int n,m,s1,s2,s4,s3,sf,k,s5,s6,mx,s7,s8,s9,mx2,res,dem2=0,dem=0,s33,dem3,dem4,l,r,mid,l2,r2,center;
int i,s10,s12;
int kk;
int el=19;
main()
{
#ifndef ONLINE_JUDGE
// fin(task);
// fou(task);
#endif
NHP
/// cin>>s1;
///modwwe
phongbeo();
checktime
}
vector<ic> v[900001];
vector<int> v2,v3;
map<int,int>cnt[300001];
set<int> s[300001];
multiset<int>ss[300001];
vector<ib> ask[900001];
id a[300001];
int ans[300001];
ib b[300001];
struct IT
{
int t[1200001];
void upd(int node,int l,int r,int l1)
{
if(l==r)
{
if(ss[l].size()==0)t[node]=0;
else t[node]=*ss[l].rbegin();
return;
}
int mid=l+r>>1;
if(l1<=mid) upd(node<<1,l,mid,l1);
else upd(node<<1|1,mid+1,r,l1);
t[node]=max(t[node<<1],t[node<<1|1]);
}
int get(int node,int l,int r,int l1)
{
if(r<=l1) return t[node];
int mid=l+r>>1;
if(mid+1<=l1) return max(get(node<<1|1,mid+1,r,l1),get(node<<1,l,mid,l1));
else return get(node<<1,l,mid,l1);
}
} st;
void add2(int x,int y)
{
/// if(x==1&&y==inf) cout<<"fafafafafaf",debug
ss[x].insert(y);
st.upd(1,1,n,x);
}
void dell2(int x,int y)
{ auto it=ss[x].lower_bound(y);
ss[x].erase(it);
st.upd(1,1,n,x);
}
void add(int x,int y)
{
cnt[y][x]++;
if(cnt[y][x]>1) return;
auto it=s[y].lower_bound(x);
s2=-1;
if(it!=s[y].end()) add2(x,*it),s2=*it;
if(it!=s[y].begin())
{
it--;
auto it2=it;
add2(*it2,x);
if(s2!=-1){
/// if(*it2==1&&s2==inf) cout<<y<<" "<<v2[x-1]<<"\n";
dell2(*it2,s2);}
}
if(s[y].size()==2)dem++;
if(cnt[y][x]==1)
s[y].insert(x);
}
void del(int x,int y)
{
cnt[y][x]--;
if(cnt[y][x]==0)
{
s[y].erase(x);
if(s[y].size()==2) dem--;
auto it=s[y].lower_bound(x);
s2=-1;
if(it!=s[y].end()) dell2(x,*it),s2=*it;
if(it!=s[y].begin())
{
it--;
auto it2=it;
dell2(*it2,x);
if(s2!=-1){
add2(*it2,s2);
}
}
}
}
bool check(int x,int y)
{
s2=lower_bound(v2.begin(),v2.end(),x-y)-v2.begin();
s2=max(s2,1);
s3=st.get(1,1,n,s2);
if(s3>v2.size()) return 0;
return v2[s3-1]<=x+y;
}
int get(int x)
{
l=0;
r=max(s12-x,x);
while(l<=r)
{
int mid=l+r>>1;
if(check(x,mid))r=mid-1;
else l=mid+1;
}
return r+1;
}
void phongbeo()
{
n=scan();
k=scan();
m=scan();
v2.pb(0);
for(int i=1; i<=n; i++)
l=scan(),r=scan(),s2=scan(),s3=scan(),a[i]= {l,r,s2,s3},v3.pb(s2),v3.pb(s3+1),v2.pb(l),s12=max(s12,l);
for(int i=1; i<=m; i++)
l=scan(),r=scan(),b[i]= {l,r},v3.pb(r);
sort(v2.begin(),v2.end());
v2.erase(unique(v2.begin(), v2.end()), v2.end());
sort(v3.begin(),v3.end());
v3.erase(unique(v3.begin(), v3.end()), v3.end());
for(int i=1; i<=n; i++)
{
s2=lower_bound(v3.begin(),v3.end(),a[i].c)-v3.begin()+1;
s3=lower_bound(v3.begin(),v3.end(),a[i].d+1)-v3.begin()+1;
l=lower_bound(v2.begin(),v2.end(),a[i].a)-v2.begin()+1;
r=a[i].b;
v[s2].pb({l,r,1}),v[s3].pb({l,r,-1});
}
for(int i=1; i<=m; i++)
{
l=b[i].a;
r=b[i].b;
r=lower_bound(v3.begin(),v3.end(),r)-v3.begin()+1;
ask[r].pb({l,i});
}
for(int i=1; i<=k; i++)
ss[1].insert(inf),
s[i].insert(1),s[i].insert(inf);
n++;
st.upd(1,1,n,1);
dem=0;
for(int i=1; i<=v3.size(); i++)
{
for(auto f:v[i])
{
if(f.c==1)
{
add(f.a,f.b);
}
else
del(f.a,f.b);
}
for(auto f:ask[i])
{
if(dem==k)
ans[f.b]=get(f.a);
else ans[f.b]=-1;
}
}
for(int i=1; i<=m; i++)
cout<<ans[i],down
}
/**
3 1 1
4 1 7 8
3 1 1 3
9 1 1 9
2 2
*/
Compilation message
new_home.cpp:67:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
67 | main()
| ^~~~
new_home.cpp: In member function 'void IT::upd(int, int, int, int)':
new_home.cpp:99:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
99 | int mid=l+r>>1;
| ~^~
new_home.cpp: In member function 'int IT::get(int, int, int, int)':
new_home.cpp:107:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
107 | int mid=l+r>>1;
| ~^~
new_home.cpp: In function 'bool check(int, int)':
new_home.cpp:173:7: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
173 | if(s3>v2.size()) return 0;
| ~~^~~~~~~~~~
new_home.cpp: In function 'int get(int)':
new_home.cpp:182:18: warning: suggest parentheses around '+' inside '>>' [-Wparentheses]
182 | int mid=l+r>>1;
| ~^~
new_home.cpp: In function 'void phongbeo()':
new_home.cpp:224:19: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
224 | for(int i=1; i<=v3.size(); i++)
| ~^~~~~~~~~~~
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
40 ms |
84816 KB |
Output is correct |
2 |
Correct |
43 ms |
84820 KB |
Output is correct |
3 |
Correct |
43 ms |
84820 KB |
Output is correct |
4 |
Correct |
44 ms |
85000 KB |
Output is correct |
5 |
Correct |
45 ms |
85076 KB |
Output is correct |
6 |
Correct |
43 ms |
85052 KB |
Output is correct |
7 |
Correct |
42 ms |
85084 KB |
Output is correct |
8 |
Correct |
40 ms |
85076 KB |
Output is correct |
9 |
Correct |
40 ms |
85032 KB |
Output is correct |
10 |
Correct |
40 ms |
84960 KB |
Output is correct |
11 |
Correct |
38 ms |
85084 KB |
Output is correct |
12 |
Correct |
38 ms |
85084 KB |
Output is correct |
13 |
Correct |
38 ms |
85084 KB |
Output is correct |
14 |
Correct |
38 ms |
85080 KB |
Output is correct |
15 |
Correct |
39 ms |
85076 KB |
Output is correct |
16 |
Correct |
38 ms |
85084 KB |
Output is correct |
17 |
Correct |
46 ms |
85032 KB |
Output is correct |
18 |
Correct |
38 ms |
85084 KB |
Output is correct |
19 |
Correct |
38 ms |
85080 KB |
Output is correct |
20 |
Correct |
38 ms |
85084 KB |
Output is correct |
21 |
Correct |
38 ms |
85080 KB |
Output is correct |
22 |
Correct |
38 ms |
85076 KB |
Output is correct |
23 |
Correct |
38 ms |
85012 KB |
Output is correct |
24 |
Correct |
40 ms |
85028 KB |
Output is correct |
25 |
Correct |
45 ms |
85076 KB |
Output is correct |
26 |
Correct |
40 ms |
85072 KB |
Output is correct |
27 |
Correct |
39 ms |
85076 KB |
Output is correct |
28 |
Correct |
40 ms |
85072 KB |
Output is correct |
29 |
Correct |
39 ms |
85072 KB |
Output is correct |
30 |
Correct |
43 ms |
85080 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
40 ms |
84816 KB |
Output is correct |
2 |
Correct |
43 ms |
84820 KB |
Output is correct |
3 |
Correct |
43 ms |
84820 KB |
Output is correct |
4 |
Correct |
44 ms |
85000 KB |
Output is correct |
5 |
Correct |
45 ms |
85076 KB |
Output is correct |
6 |
Correct |
43 ms |
85052 KB |
Output is correct |
7 |
Correct |
42 ms |
85084 KB |
Output is correct |
8 |
Correct |
40 ms |
85076 KB |
Output is correct |
9 |
Correct |
40 ms |
85032 KB |
Output is correct |
10 |
Correct |
40 ms |
84960 KB |
Output is correct |
11 |
Correct |
38 ms |
85084 KB |
Output is correct |
12 |
Correct |
38 ms |
85084 KB |
Output is correct |
13 |
Correct |
38 ms |
85084 KB |
Output is correct |
14 |
Correct |
38 ms |
85080 KB |
Output is correct |
15 |
Correct |
39 ms |
85076 KB |
Output is correct |
16 |
Correct |
38 ms |
85084 KB |
Output is correct |
17 |
Correct |
46 ms |
85032 KB |
Output is correct |
18 |
Correct |
38 ms |
85084 KB |
Output is correct |
19 |
Correct |
38 ms |
85080 KB |
Output is correct |
20 |
Correct |
38 ms |
85084 KB |
Output is correct |
21 |
Correct |
38 ms |
85080 KB |
Output is correct |
22 |
Correct |
38 ms |
85076 KB |
Output is correct |
23 |
Correct |
38 ms |
85012 KB |
Output is correct |
24 |
Correct |
40 ms |
85028 KB |
Output is correct |
25 |
Correct |
45 ms |
85076 KB |
Output is correct |
26 |
Correct |
40 ms |
85072 KB |
Output is correct |
27 |
Correct |
39 ms |
85076 KB |
Output is correct |
28 |
Correct |
40 ms |
85072 KB |
Output is correct |
29 |
Correct |
39 ms |
85072 KB |
Output is correct |
30 |
Correct |
43 ms |
85080 KB |
Output is correct |
31 |
Correct |
393 ms |
105668 KB |
Output is correct |
32 |
Correct |
70 ms |
91080 KB |
Output is correct |
33 |
Correct |
443 ms |
101064 KB |
Output is correct |
34 |
Correct |
390 ms |
101312 KB |
Output is correct |
35 |
Correct |
439 ms |
105416 KB |
Output is correct |
36 |
Correct |
452 ms |
105436 KB |
Output is correct |
37 |
Correct |
379 ms |
100108 KB |
Output is correct |
38 |
Correct |
389 ms |
99840 KB |
Output is correct |
39 |
Correct |
333 ms |
99780 KB |
Output is correct |
40 |
Correct |
355 ms |
99780 KB |
Output is correct |
41 |
Correct |
293 ms |
100036 KB |
Output is correct |
42 |
Correct |
251 ms |
99780 KB |
Output is correct |
43 |
Correct |
93 ms |
92812 KB |
Output is correct |
44 |
Correct |
317 ms |
100056 KB |
Output is correct |
45 |
Correct |
308 ms |
99928 KB |
Output is correct |
46 |
Correct |
311 ms |
99784 KB |
Output is correct |
47 |
Correct |
213 ms |
99272 KB |
Output is correct |
48 |
Correct |
223 ms |
99016 KB |
Output is correct |
49 |
Correct |
256 ms |
99272 KB |
Output is correct |
50 |
Correct |
235 ms |
99780 KB |
Output is correct |
51 |
Correct |
276 ms |
99272 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1640 ms |
185388 KB |
Output is correct |
2 |
Correct |
2551 ms |
174520 KB |
Output is correct |
3 |
Correct |
1742 ms |
219420 KB |
Output is correct |
4 |
Correct |
1741 ms |
191176 KB |
Output is correct |
5 |
Correct |
2459 ms |
174192 KB |
Output is correct |
6 |
Correct |
2494 ms |
174508 KB |
Output is correct |
7 |
Correct |
1554 ms |
219428 KB |
Output is correct |
8 |
Correct |
1339 ms |
190988 KB |
Output is correct |
9 |
Correct |
1376 ms |
181004 KB |
Output is correct |
10 |
Correct |
1902 ms |
175628 KB |
Output is correct |
11 |
Correct |
1454 ms |
173548 KB |
Output is correct |
12 |
Correct |
1518 ms |
175364 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
2089 ms |
182684 KB |
Output is correct |
2 |
Correct |
166 ms |
113308 KB |
Output is correct |
3 |
Correct |
2801 ms |
180372 KB |
Output is correct |
4 |
Correct |
1519 ms |
223136 KB |
Output is correct |
5 |
Correct |
1363 ms |
189220 KB |
Output is correct |
6 |
Correct |
1391 ms |
194872 KB |
Output is correct |
7 |
Correct |
2798 ms |
179708 KB |
Output is correct |
8 |
Correct |
2848 ms |
180120 KB |
Output is correct |
9 |
Correct |
1767 ms |
224324 KB |
Output is correct |
10 |
Correct |
1700 ms |
192484 KB |
Output is correct |
11 |
Correct |
1781 ms |
184212 KB |
Output is correct |
12 |
Correct |
2448 ms |
181260 KB |
Output is correct |
13 |
Correct |
1380 ms |
177568 KB |
Output is correct |
14 |
Correct |
1362 ms |
176732 KB |
Output is correct |
15 |
Correct |
1560 ms |
178848 KB |
Output is correct |
16 |
Correct |
1729 ms |
180568 KB |
Output is correct |
17 |
Correct |
1782 ms |
178396 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
40 ms |
84816 KB |
Output is correct |
2 |
Correct |
43 ms |
84820 KB |
Output is correct |
3 |
Correct |
43 ms |
84820 KB |
Output is correct |
4 |
Correct |
44 ms |
85000 KB |
Output is correct |
5 |
Correct |
45 ms |
85076 KB |
Output is correct |
6 |
Correct |
43 ms |
85052 KB |
Output is correct |
7 |
Correct |
42 ms |
85084 KB |
Output is correct |
8 |
Correct |
40 ms |
85076 KB |
Output is correct |
9 |
Correct |
40 ms |
85032 KB |
Output is correct |
10 |
Correct |
40 ms |
84960 KB |
Output is correct |
11 |
Correct |
38 ms |
85084 KB |
Output is correct |
12 |
Correct |
38 ms |
85084 KB |
Output is correct |
13 |
Correct |
38 ms |
85084 KB |
Output is correct |
14 |
Correct |
38 ms |
85080 KB |
Output is correct |
15 |
Correct |
39 ms |
85076 KB |
Output is correct |
16 |
Correct |
38 ms |
85084 KB |
Output is correct |
17 |
Correct |
46 ms |
85032 KB |
Output is correct |
18 |
Correct |
38 ms |
85084 KB |
Output is correct |
19 |
Correct |
38 ms |
85080 KB |
Output is correct |
20 |
Correct |
38 ms |
85084 KB |
Output is correct |
21 |
Correct |
38 ms |
85080 KB |
Output is correct |
22 |
Correct |
38 ms |
85076 KB |
Output is correct |
23 |
Correct |
38 ms |
85012 KB |
Output is correct |
24 |
Correct |
40 ms |
85028 KB |
Output is correct |
25 |
Correct |
45 ms |
85076 KB |
Output is correct |
26 |
Correct |
40 ms |
85072 KB |
Output is correct |
27 |
Correct |
39 ms |
85076 KB |
Output is correct |
28 |
Correct |
40 ms |
85072 KB |
Output is correct |
29 |
Correct |
39 ms |
85072 KB |
Output is correct |
30 |
Correct |
43 ms |
85080 KB |
Output is correct |
31 |
Correct |
393 ms |
105668 KB |
Output is correct |
32 |
Correct |
70 ms |
91080 KB |
Output is correct |
33 |
Correct |
443 ms |
101064 KB |
Output is correct |
34 |
Correct |
390 ms |
101312 KB |
Output is correct |
35 |
Correct |
439 ms |
105416 KB |
Output is correct |
36 |
Correct |
452 ms |
105436 KB |
Output is correct |
37 |
Correct |
379 ms |
100108 KB |
Output is correct |
38 |
Correct |
389 ms |
99840 KB |
Output is correct |
39 |
Correct |
333 ms |
99780 KB |
Output is correct |
40 |
Correct |
355 ms |
99780 KB |
Output is correct |
41 |
Correct |
293 ms |
100036 KB |
Output is correct |
42 |
Correct |
251 ms |
99780 KB |
Output is correct |
43 |
Correct |
93 ms |
92812 KB |
Output is correct |
44 |
Correct |
317 ms |
100056 KB |
Output is correct |
45 |
Correct |
308 ms |
99928 KB |
Output is correct |
46 |
Correct |
311 ms |
99784 KB |
Output is correct |
47 |
Correct |
213 ms |
99272 KB |
Output is correct |
48 |
Correct |
223 ms |
99016 KB |
Output is correct |
49 |
Correct |
256 ms |
99272 KB |
Output is correct |
50 |
Correct |
235 ms |
99780 KB |
Output is correct |
51 |
Correct |
276 ms |
99272 KB |
Output is correct |
52 |
Correct |
292 ms |
113864 KB |
Output is correct |
53 |
Correct |
255 ms |
109532 KB |
Output is correct |
54 |
Correct |
252 ms |
108040 KB |
Output is correct |
55 |
Correct |
311 ms |
104644 KB |
Output is correct |
56 |
Correct |
330 ms |
106956 KB |
Output is correct |
57 |
Correct |
319 ms |
101576 KB |
Output is correct |
58 |
Correct |
286 ms |
104484 KB |
Output is correct |
59 |
Correct |
288 ms |
106692 KB |
Output is correct |
60 |
Correct |
283 ms |
100800 KB |
Output is correct |
61 |
Correct |
152 ms |
109248 KB |
Output is correct |
62 |
Correct |
324 ms |
113860 KB |
Output is correct |
63 |
Correct |
288 ms |
108488 KB |
Output is correct |
64 |
Correct |
294 ms |
105924 KB |
Output is correct |
65 |
Correct |
283 ms |
101824 KB |
Output is correct |
66 |
Correct |
287 ms |
100040 KB |
Output is correct |
67 |
Correct |
163 ms |
95716 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
40 ms |
84816 KB |
Output is correct |
2 |
Correct |
43 ms |
84820 KB |
Output is correct |
3 |
Correct |
43 ms |
84820 KB |
Output is correct |
4 |
Correct |
44 ms |
85000 KB |
Output is correct |
5 |
Correct |
45 ms |
85076 KB |
Output is correct |
6 |
Correct |
43 ms |
85052 KB |
Output is correct |
7 |
Correct |
42 ms |
85084 KB |
Output is correct |
8 |
Correct |
40 ms |
85076 KB |
Output is correct |
9 |
Correct |
40 ms |
85032 KB |
Output is correct |
10 |
Correct |
40 ms |
84960 KB |
Output is correct |
11 |
Correct |
38 ms |
85084 KB |
Output is correct |
12 |
Correct |
38 ms |
85084 KB |
Output is correct |
13 |
Correct |
38 ms |
85084 KB |
Output is correct |
14 |
Correct |
38 ms |
85080 KB |
Output is correct |
15 |
Correct |
39 ms |
85076 KB |
Output is correct |
16 |
Correct |
38 ms |
85084 KB |
Output is correct |
17 |
Correct |
46 ms |
85032 KB |
Output is correct |
18 |
Correct |
38 ms |
85084 KB |
Output is correct |
19 |
Correct |
38 ms |
85080 KB |
Output is correct |
20 |
Correct |
38 ms |
85084 KB |
Output is correct |
21 |
Correct |
38 ms |
85080 KB |
Output is correct |
22 |
Correct |
38 ms |
85076 KB |
Output is correct |
23 |
Correct |
38 ms |
85012 KB |
Output is correct |
24 |
Correct |
40 ms |
85028 KB |
Output is correct |
25 |
Correct |
45 ms |
85076 KB |
Output is correct |
26 |
Correct |
40 ms |
85072 KB |
Output is correct |
27 |
Correct |
39 ms |
85076 KB |
Output is correct |
28 |
Correct |
40 ms |
85072 KB |
Output is correct |
29 |
Correct |
39 ms |
85072 KB |
Output is correct |
30 |
Correct |
43 ms |
85080 KB |
Output is correct |
31 |
Correct |
393 ms |
105668 KB |
Output is correct |
32 |
Correct |
70 ms |
91080 KB |
Output is correct |
33 |
Correct |
443 ms |
101064 KB |
Output is correct |
34 |
Correct |
390 ms |
101312 KB |
Output is correct |
35 |
Correct |
439 ms |
105416 KB |
Output is correct |
36 |
Correct |
452 ms |
105436 KB |
Output is correct |
37 |
Correct |
379 ms |
100108 KB |
Output is correct |
38 |
Correct |
389 ms |
99840 KB |
Output is correct |
39 |
Correct |
333 ms |
99780 KB |
Output is correct |
40 |
Correct |
355 ms |
99780 KB |
Output is correct |
41 |
Correct |
293 ms |
100036 KB |
Output is correct |
42 |
Correct |
251 ms |
99780 KB |
Output is correct |
43 |
Correct |
93 ms |
92812 KB |
Output is correct |
44 |
Correct |
317 ms |
100056 KB |
Output is correct |
45 |
Correct |
308 ms |
99928 KB |
Output is correct |
46 |
Correct |
311 ms |
99784 KB |
Output is correct |
47 |
Correct |
213 ms |
99272 KB |
Output is correct |
48 |
Correct |
223 ms |
99016 KB |
Output is correct |
49 |
Correct |
256 ms |
99272 KB |
Output is correct |
50 |
Correct |
235 ms |
99780 KB |
Output is correct |
51 |
Correct |
276 ms |
99272 KB |
Output is correct |
52 |
Correct |
1640 ms |
185388 KB |
Output is correct |
53 |
Correct |
2551 ms |
174520 KB |
Output is correct |
54 |
Correct |
1742 ms |
219420 KB |
Output is correct |
55 |
Correct |
1741 ms |
191176 KB |
Output is correct |
56 |
Correct |
2459 ms |
174192 KB |
Output is correct |
57 |
Correct |
2494 ms |
174508 KB |
Output is correct |
58 |
Correct |
1554 ms |
219428 KB |
Output is correct |
59 |
Correct |
1339 ms |
190988 KB |
Output is correct |
60 |
Correct |
1376 ms |
181004 KB |
Output is correct |
61 |
Correct |
1902 ms |
175628 KB |
Output is correct |
62 |
Correct |
1454 ms |
173548 KB |
Output is correct |
63 |
Correct |
1518 ms |
175364 KB |
Output is correct |
64 |
Correct |
2089 ms |
182684 KB |
Output is correct |
65 |
Correct |
166 ms |
113308 KB |
Output is correct |
66 |
Correct |
2801 ms |
180372 KB |
Output is correct |
67 |
Correct |
1519 ms |
223136 KB |
Output is correct |
68 |
Correct |
1363 ms |
189220 KB |
Output is correct |
69 |
Correct |
1391 ms |
194872 KB |
Output is correct |
70 |
Correct |
2798 ms |
179708 KB |
Output is correct |
71 |
Correct |
2848 ms |
180120 KB |
Output is correct |
72 |
Correct |
1767 ms |
224324 KB |
Output is correct |
73 |
Correct |
1700 ms |
192484 KB |
Output is correct |
74 |
Correct |
1781 ms |
184212 KB |
Output is correct |
75 |
Correct |
2448 ms |
181260 KB |
Output is correct |
76 |
Correct |
1380 ms |
177568 KB |
Output is correct |
77 |
Correct |
1362 ms |
176732 KB |
Output is correct |
78 |
Correct |
1560 ms |
178848 KB |
Output is correct |
79 |
Correct |
1729 ms |
180568 KB |
Output is correct |
80 |
Correct |
1782 ms |
178396 KB |
Output is correct |
81 |
Correct |
292 ms |
113864 KB |
Output is correct |
82 |
Correct |
255 ms |
109532 KB |
Output is correct |
83 |
Correct |
252 ms |
108040 KB |
Output is correct |
84 |
Correct |
311 ms |
104644 KB |
Output is correct |
85 |
Correct |
330 ms |
106956 KB |
Output is correct |
86 |
Correct |
319 ms |
101576 KB |
Output is correct |
87 |
Correct |
286 ms |
104484 KB |
Output is correct |
88 |
Correct |
288 ms |
106692 KB |
Output is correct |
89 |
Correct |
283 ms |
100800 KB |
Output is correct |
90 |
Correct |
152 ms |
109248 KB |
Output is correct |
91 |
Correct |
324 ms |
113860 KB |
Output is correct |
92 |
Correct |
288 ms |
108488 KB |
Output is correct |
93 |
Correct |
294 ms |
105924 KB |
Output is correct |
94 |
Correct |
283 ms |
101824 KB |
Output is correct |
95 |
Correct |
287 ms |
100040 KB |
Output is correct |
96 |
Correct |
163 ms |
95716 KB |
Output is correct |
97 |
Correct |
1678 ms |
231076 KB |
Output is correct |
98 |
Correct |
189 ms |
115368 KB |
Output is correct |
99 |
Correct |
2835 ms |
166356 KB |
Output is correct |
100 |
Correct |
1602 ms |
209060 KB |
Output is correct |
101 |
Correct |
1605 ms |
202612 KB |
Output is correct |
102 |
Correct |
3073 ms |
188188 KB |
Output is correct |
103 |
Correct |
2283 ms |
161684 KB |
Output is correct |
104 |
Correct |
2299 ms |
161164 KB |
Output is correct |
105 |
Correct |
1784 ms |
159928 KB |
Output is correct |
106 |
Correct |
1936 ms |
159904 KB |
Output is correct |
107 |
Correct |
1843 ms |
184788 KB |
Output is correct |
108 |
Correct |
1897 ms |
195384 KB |
Output is correct |
109 |
Correct |
1797 ms |
169112 KB |
Output is correct |
110 |
Correct |
1730 ms |
183428 KB |
Output is correct |
111 |
Correct |
1776 ms |
195568 KB |
Output is correct |
112 |
Correct |
1635 ms |
166268 KB |
Output is correct |
113 |
Correct |
707 ms |
207116 KB |
Output is correct |
114 |
Correct |
1843 ms |
231504 KB |
Output is correct |
115 |
Correct |
1928 ms |
204364 KB |
Output is correct |
116 |
Correct |
1988 ms |
192120 KB |
Output is correct |
117 |
Correct |
1867 ms |
171492 KB |
Output is correct |
118 |
Correct |
1865 ms |
162708 KB |
Output is correct |
119 |
Correct |
1043 ms |
138768 KB |
Output is correct |
120 |
Correct |
920 ms |
154968 KB |
Output is correct |
121 |
Correct |
1221 ms |
157996 KB |
Output is correct |
122 |
Correct |
1278 ms |
157444 KB |
Output is correct |
123 |
Correct |
1431 ms |
158888 KB |
Output is correct |
124 |
Correct |
1419 ms |
160252 KB |
Output is correct |
125 |
Correct |
1634 ms |
159268 KB |
Output is correct |
126 |
Correct |
1355 ms |
160440 KB |
Output is correct |