#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef long double ld;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
#define ff first
#define ss second
ll ttt;
const ll INF=1e18;
const ll MOD=1e9+7;
const ll N=307;
ll n,m,k;
int h, v;
bool dp[N][N];
bool vis[N][N];
bool d[N][N];
int pf[2*N][2*N];
int colpf[2*N][2*N];
int tgi,tgj;
int getPf(int i, int j1, int j2){
if(j1==0)return pf[i][j2];
return pf[i][j2]-pf[i][j1-1];
}
int getColPf(int j, int i1, int i2){
if(i1==0)return colpf[j][i2];
return colpf[j][i2]-colpf[j][i1-1];
}
void recurs(int i, int j){
if(vis[i][j])return;
vis[i][j]=true;
if(!dp[i][j])return;
// cout<<i<<" "<<j<<endl;
//left
if(j>0&&!d[i][j-1]){
for(int vi=max(0,i-v+1);vi<=i&&vi+v<=n;vi++){
if(getColPf(j,vi,vi+v-1)==0 &&
getColPf(j-1,vi,vi+v-1)==0){
dp[i][j-1]=true;
recurs(i,j-1);
break;
}
}
}
//right
if(j<m-1&&!d[i][j+1]){
for(int vi=max(0,i-v+1);vi<=i&&vi+v<=n;vi++){
if(getColPf(j,vi,vi+v-1)==0 &&
getColPf(j+1,vi,vi+v-1)==0){
dp[i][j+1]=true;
recurs(i,j+1);
break;
}
}
}
//up
if(i>0&&!d[i-1][j]){
// cout<<"OK "<<i<<" "<<j<<endl;
for(int hj=max(0,j-h+1);hj<=j&&hj+h<=m;hj++){
// cout<<hj<<": "<<getPf(i,hj,hj+h-1)<<", "<<getPf(i-1,hj,hj+h-1)<<endl;
if(getPf(i,hj,hj+h-1)==0 &&
getPf(i-1,hj,hj+h-1)==0){
dp[i-1][j]=true;
recurs(i-1,j);
break;
}
}
}
//down
if(i<n-1&&!d[i+1][j]){
for(int hj=max(0,j-h+1);hj<=j&&hj+h<=m;hj++){
if(getPf(i,hj,hj+h-1)==0 &&
getPf(i+1,hj,hj+h-1)==0){
dp[i+1][j]=true;
recurs(i+1,j);
break;
}
}
}
}
void calculatePfs(){
for(int i=0;i<n;i++){
pf[i][0]=d[i][0];
for(int j=1;j<2*m;j++){
pf[i][j]=pf[i][j-1]+d[i][j];
}
}
for(int j=0;j<m;j++){
colpf[j][0]=d[0][j];
for(int i=1;i<2*n;i++){
colpf[j][i]=colpf[j][i-1]+d[i][j];
}
}
}
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
// freopen("Dinput.txt","r",stdin);
// freopen("Doutput.txt","w",stdout);
cin>>m>>n;
cin>>h>>v;
int i1,i2,j1,j2;
cin>>j1>>i1>>j2>>i2;
for(int i=0;i<n;i++){
for(int j=0;j<m;j++){
char c;
cin>>c;
// cout<<c;
if(c=='X'){
d[i][j]=true;
}
if(c=='*'){
tgi=i;
tgj=j;
// cout<<i<<" "<<j<<endl;
}
}
// cout<<endl;
}
calculatePfs();
int ii=i1;
int jj=j2;
dp[ii][jj]=true;
recurs(ii,jj);
if(dp[tgi][tgj]){
// cout<<tgi<<" "<<tgj<<endl;
// cout<<lh<<" "<<lv<<endl;
cout<<"YES"<<endl;
return 0;
}
cout<<"NO"<<endl;
return 0;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2396 KB |
Output is correct |
2 |
Correct |
0 ms |
2396 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2396 KB |
Output is correct |
2 |
Correct |
0 ms |
2396 KB |
Output is correct |
3 |
Correct |
1 ms |
2652 KB |
Output is correct |
4 |
Correct |
0 ms |
2908 KB |
Output is correct |
5 |
Correct |
0 ms |
2652 KB |
Output is correct |
6 |
Correct |
0 ms |
2396 KB |
Output is correct |
7 |
Correct |
0 ms |
2652 KB |
Output is correct |
8 |
Correct |
0 ms |
2652 KB |
Output is correct |
9 |
Correct |
0 ms |
2396 KB |
Output is correct |
10 |
Correct |
0 ms |
2652 KB |
Output is correct |
11 |
Correct |
0 ms |
2652 KB |
Output is correct |
12 |
Correct |
0 ms |
2396 KB |
Output is correct |
13 |
Correct |
0 ms |
2652 KB |
Output is correct |
14 |
Correct |
0 ms |
2444 KB |
Output is correct |
15 |
Correct |
1 ms |
3160 KB |
Output is correct |
16 |
Correct |
1 ms |
2908 KB |
Output is correct |
17 |
Correct |
1 ms |
2908 KB |
Output is correct |
18 |
Correct |
1 ms |
3164 KB |
Output is correct |
19 |
Correct |
1 ms |
3164 KB |
Output is correct |
20 |
Correct |
0 ms |
3164 KB |
Output is correct |
21 |
Correct |
1 ms |
3160 KB |
Output is correct |
22 |
Correct |
1 ms |
3164 KB |
Output is correct |
23 |
Correct |
1 ms |
3164 KB |
Output is correct |
24 |
Correct |
1 ms |
2908 KB |
Output is correct |
25 |
Correct |
1 ms |
2908 KB |
Output is correct |
26 |
Correct |
1 ms |
2908 KB |
Output is correct |
27 |
Correct |
1 ms |
2908 KB |
Output is correct |
28 |
Correct |
0 ms |
2908 KB |
Output is correct |
29 |
Correct |
0 ms |
2908 KB |
Output is correct |
30 |
Correct |
1 ms |
2908 KB |
Output is correct |
31 |
Correct |
1 ms |
2908 KB |
Output is correct |
32 |
Correct |
1 ms |
2908 KB |
Output is correct |
33 |
Correct |
0 ms |
2908 KB |
Output is correct |
34 |
Correct |
1 ms |
2908 KB |
Output is correct |
35 |
Correct |
0 ms |
2908 KB |
Output is correct |
36 |
Correct |
1 ms |
2648 KB |
Output is correct |
37 |
Correct |
0 ms |
2652 KB |
Output is correct |
38 |
Correct |
1 ms |
2652 KB |
Output is correct |
39 |
Correct |
1 ms |
2652 KB |
Output is correct |
40 |
Correct |
1 ms |
2652 KB |
Output is correct |
41 |
Correct |
0 ms |
2652 KB |
Output is correct |
42 |
Correct |
0 ms |
2908 KB |
Output is correct |
43 |
Correct |
0 ms |
2908 KB |
Output is correct |
44 |
Correct |
0 ms |
2908 KB |
Output is correct |
45 |
Correct |
1 ms |
2908 KB |
Output is correct |
46 |
Correct |
0 ms |
2652 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2396 KB |
Output is correct |
2 |
Correct |
0 ms |
2396 KB |
Output is correct |
3 |
Correct |
1 ms |
2652 KB |
Output is correct |
4 |
Correct |
0 ms |
2908 KB |
Output is correct |
5 |
Correct |
0 ms |
2652 KB |
Output is correct |
6 |
Correct |
0 ms |
2396 KB |
Output is correct |
7 |
Correct |
0 ms |
2652 KB |
Output is correct |
8 |
Correct |
0 ms |
2652 KB |
Output is correct |
9 |
Correct |
0 ms |
2396 KB |
Output is correct |
10 |
Correct |
0 ms |
2652 KB |
Output is correct |
11 |
Correct |
0 ms |
2652 KB |
Output is correct |
12 |
Correct |
0 ms |
2396 KB |
Output is correct |
13 |
Correct |
0 ms |
2652 KB |
Output is correct |
14 |
Correct |
0 ms |
2444 KB |
Output is correct |
15 |
Correct |
1 ms |
3160 KB |
Output is correct |
16 |
Correct |
1 ms |
2908 KB |
Output is correct |
17 |
Correct |
1 ms |
2908 KB |
Output is correct |
18 |
Correct |
1 ms |
3164 KB |
Output is correct |
19 |
Correct |
1 ms |
3164 KB |
Output is correct |
20 |
Correct |
0 ms |
3164 KB |
Output is correct |
21 |
Correct |
1 ms |
3160 KB |
Output is correct |
22 |
Correct |
1 ms |
3164 KB |
Output is correct |
23 |
Correct |
1 ms |
3164 KB |
Output is correct |
24 |
Correct |
1 ms |
2908 KB |
Output is correct |
25 |
Correct |
1 ms |
2908 KB |
Output is correct |
26 |
Correct |
1 ms |
2908 KB |
Output is correct |
27 |
Correct |
1 ms |
2908 KB |
Output is correct |
28 |
Correct |
0 ms |
2908 KB |
Output is correct |
29 |
Correct |
0 ms |
2908 KB |
Output is correct |
30 |
Correct |
1 ms |
2908 KB |
Output is correct |
31 |
Correct |
1 ms |
2908 KB |
Output is correct |
32 |
Correct |
1 ms |
2908 KB |
Output is correct |
33 |
Correct |
0 ms |
2908 KB |
Output is correct |
34 |
Correct |
1 ms |
2908 KB |
Output is correct |
35 |
Correct |
0 ms |
2908 KB |
Output is correct |
36 |
Correct |
1 ms |
2648 KB |
Output is correct |
37 |
Correct |
0 ms |
2652 KB |
Output is correct |
38 |
Correct |
1 ms |
2652 KB |
Output is correct |
39 |
Correct |
1 ms |
2652 KB |
Output is correct |
40 |
Correct |
1 ms |
2652 KB |
Output is correct |
41 |
Correct |
0 ms |
2652 KB |
Output is correct |
42 |
Correct |
0 ms |
2908 KB |
Output is correct |
43 |
Correct |
0 ms |
2908 KB |
Output is correct |
44 |
Correct |
0 ms |
2908 KB |
Output is correct |
45 |
Correct |
1 ms |
2908 KB |
Output is correct |
46 |
Correct |
0 ms |
2652 KB |
Output is correct |
47 |
Correct |
0 ms |
2652 KB |
Output is correct |
48 |
Correct |
0 ms |
2652 KB |
Output is correct |
49 |
Correct |
0 ms |
2908 KB |
Output is correct |
50 |
Correct |
0 ms |
2652 KB |
Output is correct |
51 |
Correct |
0 ms |
2652 KB |
Output is correct |
52 |
Correct |
0 ms |
2652 KB |
Output is correct |
53 |
Correct |
0 ms |
2652 KB |
Output is correct |
54 |
Correct |
1 ms |
2648 KB |
Output is correct |
55 |
Correct |
1 ms |
2652 KB |
Output is correct |
56 |
Correct |
0 ms |
2396 KB |
Output is correct |
57 |
Correct |
1 ms |
2676 KB |
Output is correct |
58 |
Correct |
1 ms |
2648 KB |
Output is correct |
59 |
Correct |
1 ms |
3420 KB |
Output is correct |
60 |
Correct |
1 ms |
3416 KB |
Output is correct |
61 |
Correct |
1 ms |
3420 KB |
Output is correct |
62 |
Correct |
2 ms |
4188 KB |
Output is correct |
63 |
Correct |
1 ms |
4188 KB |
Output is correct |
64 |
Correct |
1 ms |
4188 KB |
Output is correct |
65 |
Correct |
1 ms |
4188 KB |
Output is correct |
66 |
Correct |
1 ms |
4256 KB |
Output is correct |
67 |
Correct |
2 ms |
4184 KB |
Output is correct |
68 |
Correct |
1 ms |
3932 KB |
Output is correct |
69 |
Correct |
2 ms |
3932 KB |
Output is correct |
70 |
Correct |
1 ms |
3932 KB |
Output is correct |
71 |
Correct |
1 ms |
3932 KB |
Output is correct |
72 |
Correct |
1 ms |
3932 KB |
Output is correct |
73 |
Correct |
1 ms |
3932 KB |
Output is correct |
74 |
Correct |
2 ms |
4188 KB |
Output is correct |
75 |
Correct |
1 ms |
4204 KB |
Output is correct |
76 |
Correct |
1 ms |
4188 KB |
Output is correct |
77 |
Correct |
1 ms |
4188 KB |
Output is correct |
78 |
Correct |
1 ms |
4112 KB |
Output is correct |
79 |
Correct |
1 ms |
4188 KB |
Output is correct |
80 |
Correct |
1 ms |
2648 KB |
Output is correct |
81 |
Correct |
1 ms |
3164 KB |
Output is correct |
82 |
Correct |
1 ms |
3164 KB |
Output is correct |
83 |
Correct |
1 ms |
3164 KB |
Output is correct |
84 |
Correct |
1 ms |
3164 KB |
Output is correct |
85 |
Correct |
1 ms |
3164 KB |
Output is correct |
86 |
Correct |
1 ms |
3932 KB |
Output is correct |
87 |
Correct |
1 ms |
4000 KB |
Output is correct |
88 |
Correct |
2 ms |
3676 KB |
Output is correct |
89 |
Correct |
1 ms |
3676 KB |
Output is correct |
90 |
Correct |
0 ms |
2652 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2396 KB |
Output is correct |
2 |
Correct |
0 ms |
2396 KB |
Output is correct |
3 |
Correct |
1 ms |
3164 KB |
Output is correct |
4 |
Correct |
9 ms |
13916 KB |
Output is correct |
5 |
Correct |
7 ms |
10652 KB |
Output is correct |
6 |
Correct |
1 ms |
3420 KB |
Output is correct |
7 |
Correct |
7 ms |
9052 KB |
Output is correct |
8 |
Correct |
7 ms |
7004 KB |
Output is correct |
9 |
Correct |
1 ms |
2652 KB |
Output is correct |
10 |
Correct |
1 ms |
2648 KB |
Output is correct |
11 |
Correct |
1 ms |
2652 KB |
Output is correct |
12 |
Correct |
1 ms |
2652 KB |
Output is correct |
13 |
Correct |
1 ms |
2652 KB |
Output is correct |
14 |
Correct |
2 ms |
2652 KB |
Output is correct |
15 |
Correct |
13 ms |
19480 KB |
Output is correct |
16 |
Correct |
17 ms |
15964 KB |
Output is correct |
17 |
Correct |
10 ms |
16864 KB |
Output is correct |
18 |
Correct |
13 ms |
21084 KB |
Output is correct |
19 |
Correct |
12 ms |
21084 KB |
Output is correct |
20 |
Correct |
19 ms |
21084 KB |
Output is correct |
21 |
Correct |
21 ms |
21156 KB |
Output is correct |
22 |
Correct |
18 ms |
20900 KB |
Output is correct |
23 |
Correct |
12 ms |
21084 KB |
Output is correct |
24 |
Correct |
10 ms |
16476 KB |
Output is correct |
25 |
Correct |
14 ms |
16476 KB |
Output is correct |
26 |
Correct |
11 ms |
16488 KB |
Output is correct |
27 |
Correct |
11 ms |
16476 KB |
Output is correct |
28 |
Correct |
11 ms |
16476 KB |
Output is correct |
29 |
Correct |
11 ms |
16320 KB |
Output is correct |
30 |
Correct |
13 ms |
20312 KB |
Output is correct |
31 |
Correct |
11 ms |
19548 KB |
Output is correct |
32 |
Correct |
13 ms |
20572 KB |
Output is correct |
33 |
Correct |
11 ms |
19060 KB |
Output is correct |
34 |
Correct |
12 ms |
19036 KB |
Output is correct |
35 |
Correct |
11 ms |
19036 KB |
Output is correct |
36 |
Correct |
1 ms |
2652 KB |
Output is correct |
37 |
Correct |
4 ms |
8540 KB |
Output is correct |
38 |
Correct |
5 ms |
8284 KB |
Output is correct |
39 |
Correct |
5 ms |
8284 KB |
Output is correct |
40 |
Correct |
5 ms |
8536 KB |
Output is correct |
41 |
Correct |
4 ms |
8280 KB |
Output is correct |
42 |
Correct |
13 ms |
15964 KB |
Output is correct |
43 |
Correct |
10 ms |
16176 KB |
Output is correct |
44 |
Correct |
10 ms |
16732 KB |
Output is correct |
45 |
Correct |
10 ms |
17316 KB |
Output is correct |
46 |
Correct |
1 ms |
2652 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2396 KB |
Output is correct |
2 |
Correct |
0 ms |
2396 KB |
Output is correct |
3 |
Correct |
1 ms |
2652 KB |
Output is correct |
4 |
Correct |
0 ms |
2908 KB |
Output is correct |
5 |
Correct |
0 ms |
2652 KB |
Output is correct |
6 |
Correct |
0 ms |
2396 KB |
Output is correct |
7 |
Correct |
0 ms |
2652 KB |
Output is correct |
8 |
Correct |
0 ms |
2652 KB |
Output is correct |
9 |
Correct |
0 ms |
2396 KB |
Output is correct |
10 |
Correct |
0 ms |
2652 KB |
Output is correct |
11 |
Correct |
0 ms |
2652 KB |
Output is correct |
12 |
Correct |
0 ms |
2396 KB |
Output is correct |
13 |
Correct |
0 ms |
2652 KB |
Output is correct |
14 |
Correct |
0 ms |
2444 KB |
Output is correct |
15 |
Correct |
1 ms |
3160 KB |
Output is correct |
16 |
Correct |
1 ms |
2908 KB |
Output is correct |
17 |
Correct |
1 ms |
2908 KB |
Output is correct |
18 |
Correct |
1 ms |
3164 KB |
Output is correct |
19 |
Correct |
1 ms |
3164 KB |
Output is correct |
20 |
Correct |
0 ms |
3164 KB |
Output is correct |
21 |
Correct |
1 ms |
3160 KB |
Output is correct |
22 |
Correct |
1 ms |
3164 KB |
Output is correct |
23 |
Correct |
1 ms |
3164 KB |
Output is correct |
24 |
Correct |
1 ms |
2908 KB |
Output is correct |
25 |
Correct |
1 ms |
2908 KB |
Output is correct |
26 |
Correct |
1 ms |
2908 KB |
Output is correct |
27 |
Correct |
1 ms |
2908 KB |
Output is correct |
28 |
Correct |
0 ms |
2908 KB |
Output is correct |
29 |
Correct |
0 ms |
2908 KB |
Output is correct |
30 |
Correct |
1 ms |
2908 KB |
Output is correct |
31 |
Correct |
1 ms |
2908 KB |
Output is correct |
32 |
Correct |
1 ms |
2908 KB |
Output is correct |
33 |
Correct |
0 ms |
2908 KB |
Output is correct |
34 |
Correct |
1 ms |
2908 KB |
Output is correct |
35 |
Correct |
0 ms |
2908 KB |
Output is correct |
36 |
Correct |
1 ms |
2648 KB |
Output is correct |
37 |
Correct |
0 ms |
2652 KB |
Output is correct |
38 |
Correct |
1 ms |
2652 KB |
Output is correct |
39 |
Correct |
1 ms |
2652 KB |
Output is correct |
40 |
Correct |
1 ms |
2652 KB |
Output is correct |
41 |
Correct |
0 ms |
2652 KB |
Output is correct |
42 |
Correct |
0 ms |
2908 KB |
Output is correct |
43 |
Correct |
0 ms |
2908 KB |
Output is correct |
44 |
Correct |
0 ms |
2908 KB |
Output is correct |
45 |
Correct |
1 ms |
2908 KB |
Output is correct |
46 |
Correct |
0 ms |
2652 KB |
Output is correct |
47 |
Correct |
0 ms |
2652 KB |
Output is correct |
48 |
Correct |
0 ms |
2652 KB |
Output is correct |
49 |
Correct |
0 ms |
2908 KB |
Output is correct |
50 |
Correct |
0 ms |
2652 KB |
Output is correct |
51 |
Correct |
0 ms |
2652 KB |
Output is correct |
52 |
Correct |
0 ms |
2652 KB |
Output is correct |
53 |
Correct |
0 ms |
2652 KB |
Output is correct |
54 |
Correct |
1 ms |
2648 KB |
Output is correct |
55 |
Correct |
1 ms |
2652 KB |
Output is correct |
56 |
Correct |
0 ms |
2396 KB |
Output is correct |
57 |
Correct |
1 ms |
2676 KB |
Output is correct |
58 |
Correct |
1 ms |
2648 KB |
Output is correct |
59 |
Correct |
1 ms |
3420 KB |
Output is correct |
60 |
Correct |
1 ms |
3416 KB |
Output is correct |
61 |
Correct |
1 ms |
3420 KB |
Output is correct |
62 |
Correct |
2 ms |
4188 KB |
Output is correct |
63 |
Correct |
1 ms |
4188 KB |
Output is correct |
64 |
Correct |
1 ms |
4188 KB |
Output is correct |
65 |
Correct |
1 ms |
4188 KB |
Output is correct |
66 |
Correct |
1 ms |
4256 KB |
Output is correct |
67 |
Correct |
2 ms |
4184 KB |
Output is correct |
68 |
Correct |
1 ms |
3932 KB |
Output is correct |
69 |
Correct |
2 ms |
3932 KB |
Output is correct |
70 |
Correct |
1 ms |
3932 KB |
Output is correct |
71 |
Correct |
1 ms |
3932 KB |
Output is correct |
72 |
Correct |
1 ms |
3932 KB |
Output is correct |
73 |
Correct |
1 ms |
3932 KB |
Output is correct |
74 |
Correct |
2 ms |
4188 KB |
Output is correct |
75 |
Correct |
1 ms |
4204 KB |
Output is correct |
76 |
Correct |
1 ms |
4188 KB |
Output is correct |
77 |
Correct |
1 ms |
4188 KB |
Output is correct |
78 |
Correct |
1 ms |
4112 KB |
Output is correct |
79 |
Correct |
1 ms |
4188 KB |
Output is correct |
80 |
Correct |
1 ms |
2648 KB |
Output is correct |
81 |
Correct |
1 ms |
3164 KB |
Output is correct |
82 |
Correct |
1 ms |
3164 KB |
Output is correct |
83 |
Correct |
1 ms |
3164 KB |
Output is correct |
84 |
Correct |
1 ms |
3164 KB |
Output is correct |
85 |
Correct |
1 ms |
3164 KB |
Output is correct |
86 |
Correct |
1 ms |
3932 KB |
Output is correct |
87 |
Correct |
1 ms |
4000 KB |
Output is correct |
88 |
Correct |
2 ms |
3676 KB |
Output is correct |
89 |
Correct |
1 ms |
3676 KB |
Output is correct |
90 |
Correct |
0 ms |
2652 KB |
Output is correct |
91 |
Correct |
1 ms |
3164 KB |
Output is correct |
92 |
Correct |
9 ms |
13916 KB |
Output is correct |
93 |
Correct |
7 ms |
10652 KB |
Output is correct |
94 |
Correct |
1 ms |
3420 KB |
Output is correct |
95 |
Correct |
7 ms |
9052 KB |
Output is correct |
96 |
Correct |
7 ms |
7004 KB |
Output is correct |
97 |
Correct |
1 ms |
2652 KB |
Output is correct |
98 |
Correct |
1 ms |
2648 KB |
Output is correct |
99 |
Correct |
1 ms |
2652 KB |
Output is correct |
100 |
Correct |
1 ms |
2652 KB |
Output is correct |
101 |
Correct |
1 ms |
2652 KB |
Output is correct |
102 |
Correct |
2 ms |
2652 KB |
Output is correct |
103 |
Correct |
13 ms |
19480 KB |
Output is correct |
104 |
Correct |
17 ms |
15964 KB |
Output is correct |
105 |
Correct |
10 ms |
16864 KB |
Output is correct |
106 |
Correct |
13 ms |
21084 KB |
Output is correct |
107 |
Correct |
12 ms |
21084 KB |
Output is correct |
108 |
Correct |
19 ms |
21084 KB |
Output is correct |
109 |
Correct |
21 ms |
21156 KB |
Output is correct |
110 |
Correct |
18 ms |
20900 KB |
Output is correct |
111 |
Correct |
12 ms |
21084 KB |
Output is correct |
112 |
Correct |
10 ms |
16476 KB |
Output is correct |
113 |
Correct |
14 ms |
16476 KB |
Output is correct |
114 |
Correct |
11 ms |
16488 KB |
Output is correct |
115 |
Correct |
11 ms |
16476 KB |
Output is correct |
116 |
Correct |
11 ms |
16476 KB |
Output is correct |
117 |
Correct |
11 ms |
16320 KB |
Output is correct |
118 |
Correct |
13 ms |
20312 KB |
Output is correct |
119 |
Correct |
11 ms |
19548 KB |
Output is correct |
120 |
Correct |
13 ms |
20572 KB |
Output is correct |
121 |
Correct |
11 ms |
19060 KB |
Output is correct |
122 |
Correct |
12 ms |
19036 KB |
Output is correct |
123 |
Correct |
11 ms |
19036 KB |
Output is correct |
124 |
Correct |
1 ms |
2652 KB |
Output is correct |
125 |
Correct |
4 ms |
8540 KB |
Output is correct |
126 |
Correct |
5 ms |
8284 KB |
Output is correct |
127 |
Correct |
5 ms |
8284 KB |
Output is correct |
128 |
Correct |
5 ms |
8536 KB |
Output is correct |
129 |
Correct |
4 ms |
8280 KB |
Output is correct |
130 |
Correct |
13 ms |
15964 KB |
Output is correct |
131 |
Correct |
10 ms |
16176 KB |
Output is correct |
132 |
Correct |
10 ms |
16732 KB |
Output is correct |
133 |
Correct |
10 ms |
17316 KB |
Output is correct |
134 |
Correct |
1 ms |
2652 KB |
Output is correct |
135 |
Correct |
1 ms |
2908 KB |
Output is correct |
136 |
Correct |
1 ms |
2920 KB |
Output is correct |
137 |
Correct |
1 ms |
2904 KB |
Output is correct |
138 |
Correct |
1 ms |
2652 KB |
Output is correct |
139 |
Correct |
2 ms |
2908 KB |
Output is correct |
140 |
Correct |
2 ms |
2908 KB |
Output is correct |
141 |
Correct |
1 ms |
2652 KB |
Output is correct |
142 |
Correct |
2 ms |
2904 KB |
Output is correct |
143 |
Correct |
2 ms |
2908 KB |
Output is correct |
144 |
Correct |
1 ms |
2648 KB |
Output is correct |
145 |
Correct |
2 ms |
2908 KB |
Output is correct |
146 |
Correct |
2 ms |
2908 KB |
Output is correct |
147 |
Correct |
8 ms |
12892 KB |
Output is correct |
148 |
Runtime error |
18 ms |
31188 KB |
Execution killed with signal 11 |
149 |
Halted |
0 ms |
0 KB |
- |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
2396 KB |
Output is correct |
2 |
Correct |
0 ms |
2396 KB |
Output is correct |
3 |
Correct |
1 ms |
2652 KB |
Output is correct |
4 |
Correct |
0 ms |
2908 KB |
Output is correct |
5 |
Correct |
0 ms |
2652 KB |
Output is correct |
6 |
Correct |
0 ms |
2396 KB |
Output is correct |
7 |
Correct |
0 ms |
2652 KB |
Output is correct |
8 |
Correct |
0 ms |
2652 KB |
Output is correct |
9 |
Correct |
0 ms |
2396 KB |
Output is correct |
10 |
Correct |
0 ms |
2652 KB |
Output is correct |
11 |
Correct |
0 ms |
2652 KB |
Output is correct |
12 |
Correct |
0 ms |
2396 KB |
Output is correct |
13 |
Correct |
0 ms |
2652 KB |
Output is correct |
14 |
Correct |
0 ms |
2444 KB |
Output is correct |
15 |
Correct |
1 ms |
3160 KB |
Output is correct |
16 |
Correct |
1 ms |
2908 KB |
Output is correct |
17 |
Correct |
1 ms |
2908 KB |
Output is correct |
18 |
Correct |
1 ms |
3164 KB |
Output is correct |
19 |
Correct |
1 ms |
3164 KB |
Output is correct |
20 |
Correct |
0 ms |
3164 KB |
Output is correct |
21 |
Correct |
1 ms |
3160 KB |
Output is correct |
22 |
Correct |
1 ms |
3164 KB |
Output is correct |
23 |
Correct |
1 ms |
3164 KB |
Output is correct |
24 |
Correct |
1 ms |
2908 KB |
Output is correct |
25 |
Correct |
1 ms |
2908 KB |
Output is correct |
26 |
Correct |
1 ms |
2908 KB |
Output is correct |
27 |
Correct |
1 ms |
2908 KB |
Output is correct |
28 |
Correct |
0 ms |
2908 KB |
Output is correct |
29 |
Correct |
0 ms |
2908 KB |
Output is correct |
30 |
Correct |
1 ms |
2908 KB |
Output is correct |
31 |
Correct |
1 ms |
2908 KB |
Output is correct |
32 |
Correct |
1 ms |
2908 KB |
Output is correct |
33 |
Correct |
0 ms |
2908 KB |
Output is correct |
34 |
Correct |
1 ms |
2908 KB |
Output is correct |
35 |
Correct |
0 ms |
2908 KB |
Output is correct |
36 |
Correct |
1 ms |
2648 KB |
Output is correct |
37 |
Correct |
0 ms |
2652 KB |
Output is correct |
38 |
Correct |
1 ms |
2652 KB |
Output is correct |
39 |
Correct |
1 ms |
2652 KB |
Output is correct |
40 |
Correct |
1 ms |
2652 KB |
Output is correct |
41 |
Correct |
0 ms |
2652 KB |
Output is correct |
42 |
Correct |
0 ms |
2908 KB |
Output is correct |
43 |
Correct |
0 ms |
2908 KB |
Output is correct |
44 |
Correct |
0 ms |
2908 KB |
Output is correct |
45 |
Correct |
1 ms |
2908 KB |
Output is correct |
46 |
Correct |
0 ms |
2652 KB |
Output is correct |
47 |
Correct |
0 ms |
2652 KB |
Output is correct |
48 |
Correct |
0 ms |
2652 KB |
Output is correct |
49 |
Correct |
0 ms |
2908 KB |
Output is correct |
50 |
Correct |
0 ms |
2652 KB |
Output is correct |
51 |
Correct |
0 ms |
2652 KB |
Output is correct |
52 |
Correct |
0 ms |
2652 KB |
Output is correct |
53 |
Correct |
0 ms |
2652 KB |
Output is correct |
54 |
Correct |
1 ms |
2648 KB |
Output is correct |
55 |
Correct |
1 ms |
2652 KB |
Output is correct |
56 |
Correct |
0 ms |
2396 KB |
Output is correct |
57 |
Correct |
1 ms |
2676 KB |
Output is correct |
58 |
Correct |
1 ms |
2648 KB |
Output is correct |
59 |
Correct |
1 ms |
3420 KB |
Output is correct |
60 |
Correct |
1 ms |
3416 KB |
Output is correct |
61 |
Correct |
1 ms |
3420 KB |
Output is correct |
62 |
Correct |
2 ms |
4188 KB |
Output is correct |
63 |
Correct |
1 ms |
4188 KB |
Output is correct |
64 |
Correct |
1 ms |
4188 KB |
Output is correct |
65 |
Correct |
1 ms |
4188 KB |
Output is correct |
66 |
Correct |
1 ms |
4256 KB |
Output is correct |
67 |
Correct |
2 ms |
4184 KB |
Output is correct |
68 |
Correct |
1 ms |
3932 KB |
Output is correct |
69 |
Correct |
2 ms |
3932 KB |
Output is correct |
70 |
Correct |
1 ms |
3932 KB |
Output is correct |
71 |
Correct |
1 ms |
3932 KB |
Output is correct |
72 |
Correct |
1 ms |
3932 KB |
Output is correct |
73 |
Correct |
1 ms |
3932 KB |
Output is correct |
74 |
Correct |
2 ms |
4188 KB |
Output is correct |
75 |
Correct |
1 ms |
4204 KB |
Output is correct |
76 |
Correct |
1 ms |
4188 KB |
Output is correct |
77 |
Correct |
1 ms |
4188 KB |
Output is correct |
78 |
Correct |
1 ms |
4112 KB |
Output is correct |
79 |
Correct |
1 ms |
4188 KB |
Output is correct |
80 |
Correct |
1 ms |
2648 KB |
Output is correct |
81 |
Correct |
1 ms |
3164 KB |
Output is correct |
82 |
Correct |
1 ms |
3164 KB |
Output is correct |
83 |
Correct |
1 ms |
3164 KB |
Output is correct |
84 |
Correct |
1 ms |
3164 KB |
Output is correct |
85 |
Correct |
1 ms |
3164 KB |
Output is correct |
86 |
Correct |
1 ms |
3932 KB |
Output is correct |
87 |
Correct |
1 ms |
4000 KB |
Output is correct |
88 |
Correct |
2 ms |
3676 KB |
Output is correct |
89 |
Correct |
1 ms |
3676 KB |
Output is correct |
90 |
Correct |
0 ms |
2652 KB |
Output is correct |
91 |
Correct |
1 ms |
3164 KB |
Output is correct |
92 |
Correct |
9 ms |
13916 KB |
Output is correct |
93 |
Correct |
7 ms |
10652 KB |
Output is correct |
94 |
Correct |
1 ms |
3420 KB |
Output is correct |
95 |
Correct |
7 ms |
9052 KB |
Output is correct |
96 |
Correct |
7 ms |
7004 KB |
Output is correct |
97 |
Correct |
1 ms |
2652 KB |
Output is correct |
98 |
Correct |
1 ms |
2648 KB |
Output is correct |
99 |
Correct |
1 ms |
2652 KB |
Output is correct |
100 |
Correct |
1 ms |
2652 KB |
Output is correct |
101 |
Correct |
1 ms |
2652 KB |
Output is correct |
102 |
Correct |
2 ms |
2652 KB |
Output is correct |
103 |
Correct |
13 ms |
19480 KB |
Output is correct |
104 |
Correct |
17 ms |
15964 KB |
Output is correct |
105 |
Correct |
10 ms |
16864 KB |
Output is correct |
106 |
Correct |
13 ms |
21084 KB |
Output is correct |
107 |
Correct |
12 ms |
21084 KB |
Output is correct |
108 |
Correct |
19 ms |
21084 KB |
Output is correct |
109 |
Correct |
21 ms |
21156 KB |
Output is correct |
110 |
Correct |
18 ms |
20900 KB |
Output is correct |
111 |
Correct |
12 ms |
21084 KB |
Output is correct |
112 |
Correct |
10 ms |
16476 KB |
Output is correct |
113 |
Correct |
14 ms |
16476 KB |
Output is correct |
114 |
Correct |
11 ms |
16488 KB |
Output is correct |
115 |
Correct |
11 ms |
16476 KB |
Output is correct |
116 |
Correct |
11 ms |
16476 KB |
Output is correct |
117 |
Correct |
11 ms |
16320 KB |
Output is correct |
118 |
Correct |
13 ms |
20312 KB |
Output is correct |
119 |
Correct |
11 ms |
19548 KB |
Output is correct |
120 |
Correct |
13 ms |
20572 KB |
Output is correct |
121 |
Correct |
11 ms |
19060 KB |
Output is correct |
122 |
Correct |
12 ms |
19036 KB |
Output is correct |
123 |
Correct |
11 ms |
19036 KB |
Output is correct |
124 |
Correct |
1 ms |
2652 KB |
Output is correct |
125 |
Correct |
4 ms |
8540 KB |
Output is correct |
126 |
Correct |
5 ms |
8284 KB |
Output is correct |
127 |
Correct |
5 ms |
8284 KB |
Output is correct |
128 |
Correct |
5 ms |
8536 KB |
Output is correct |
129 |
Correct |
4 ms |
8280 KB |
Output is correct |
130 |
Correct |
13 ms |
15964 KB |
Output is correct |
131 |
Correct |
10 ms |
16176 KB |
Output is correct |
132 |
Correct |
10 ms |
16732 KB |
Output is correct |
133 |
Correct |
10 ms |
17316 KB |
Output is correct |
134 |
Correct |
1 ms |
2652 KB |
Output is correct |
135 |
Correct |
1 ms |
2908 KB |
Output is correct |
136 |
Correct |
1 ms |
2920 KB |
Output is correct |
137 |
Correct |
1 ms |
2904 KB |
Output is correct |
138 |
Correct |
1 ms |
2652 KB |
Output is correct |
139 |
Correct |
2 ms |
2908 KB |
Output is correct |
140 |
Correct |
2 ms |
2908 KB |
Output is correct |
141 |
Correct |
1 ms |
2652 KB |
Output is correct |
142 |
Correct |
2 ms |
2904 KB |
Output is correct |
143 |
Correct |
2 ms |
2908 KB |
Output is correct |
144 |
Correct |
1 ms |
2648 KB |
Output is correct |
145 |
Correct |
2 ms |
2908 KB |
Output is correct |
146 |
Correct |
2 ms |
2908 KB |
Output is correct |
147 |
Correct |
8 ms |
12892 KB |
Output is correct |
148 |
Runtime error |
18 ms |
31188 KB |
Execution killed with signal 11 |
149 |
Halted |
0 ms |
0 KB |
- |