# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
1045701 |
2024-08-06T07:02:04 Z |
dilanyan |
Toy (CEOI24_toy) |
C++17 |
|
1500 ms |
15216 KB |
//-------------dilanyan------------\\
#define _CRT_SECURE_NO_WARNINGS
#include<bits/stdc++.h>
#include<stdio.h>
using namespace std;
//------------------Kargpefines--------------------\\
#define ll long long
#define pb push_back
#define all(u) (u).begin(), (u).end()
#define pqueue priority_queue
#define upper upper_bound
#define lower lower_bound
#define umap unordered_map
#define uset unordered_set
void KarginSet(string name = "") {
ios_base::sync_with_stdio(false); cin.tie(NULL);
if (name.size()) {
freopen((name + ".in").c_str(), "r", stdin);
freopen((name + ".out").c_str(), "w", stdout);
}
}
//-------------------KarginConstants------------------\\
const ll mod = 1e9 + 7;
const ll inf = 2e9;
//-------------------KarginCode-----------------------\\
const int N = 1505, M = 1000005;
int w, h, k, l;
int w_h, h_h, w_v, h_v;
char a[N][N];
int dp[N][N];
bool vis[N][N];
int dh[4] = { 1,-1,0,0 };
int dw[4] = { 0,0,1,-1 };
bool valid(int h_s, int w_s, int h_e, int w_e, int d) {
if (h_e < 0 || h_e >= h || w_e < 0 || w_e >= w) return false;
if (a[h_e][w_e] == 'X' || vis[h_e][w_e]) return false;
if (d) { // horiz
for (int i = max(0, w_s - k + 1);i <= w_s;i++) {
if (i + k > w) return false;
bool flag = true;
for (int j = i;j - i + 1 <= k;j++) {
if (a[h_s][j] == 'X' || a[h_e][j] == 'X') {
flag = false;
continue;
}
}
if (flag) return true;
}
return false;
}
else { // vertic
for (int i = max(0, h_s - l + 1);i <= h_s;i++) {
if (i + l > h) return false;
bool flag = true;
for (int j = i;j - i + 1 <= l;j++) {
if (a[j][w_s] == 'X' || a[j][w_e] == 'X') {
flag = false;
continue;
}
}
if (flag) return true;
}
return false;
}
}
void KarginSolve() {
cin >> w >> h >> k >> l;
cin >> w_h >> h_h >> w_v >> h_v;
int h_e, w_e;
for (int i = 0;i < h;i++) {
for (int j = 0;j < w;j++) {
cin >> a[i][j];
if (a[i][j] == '*') {
h_e = i, w_e = j;
}
vis[i][j] = false;
dp[i][j] = inf;
}
}
int w_s = w_v, h_s = h_h;
queue<pair<int, int>> q;
q.push({ w_s,h_s });
vis[h_s][w_s] = true;
while (!q.empty()) {
int w_u = q.front().first, h_u = q.front().second;
q.pop();
for (int i = 0;i < 4;i++) {
int h_x = h_u + dh[i], w_x = w_u + dw[i];
if (valid(h_u, w_u, h_x, w_x, (dh[i] != 0))) {
vis[h_x][w_x] = true;
q.push({ w_x,h_x });
}
}
}
if (vis[h_e][w_e]) cout << "YES\n";
else cout << "NO\n";
}
int main() {
KarginSet();
int test = 1;
//cin >> test;
while (test--) {
KarginSolve();
}
return 0;
}
Compilation message
Main.cpp:1:1: warning: multi-line comment [-Wcomment]
1 | //-------------dilanyan------------\\
| ^
Main.cpp:8:1: warning: multi-line comment [-Wcomment]
8 | //------------------Kargpefines--------------------\\
| ^
Main.cpp:27:1: warning: multi-line comment [-Wcomment]
27 | //-------------------KarginConstants------------------\\
| ^
Main.cpp:32:1: warning: multi-line comment [-Wcomment]
32 | //-------------------KarginCode-----------------------\\
| ^
Main.cpp: In function 'void KarginSet(std::string)':
Main.cpp:22:16: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
22 | freopen((name + ".in").c_str(), "r", stdin);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Main.cpp:23:16: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)' declared with attribute 'warn_unused_result' [-Wunused-result]
23 | freopen((name + ".out").c_str(), "w", stdout);
| ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Main.cpp: In function 'void KarginSolve()':
Main.cpp:108:21: warning: 'w_e' may be used uninitialized in this function [-Wmaybe-uninitialized]
108 | if (vis[h_e][w_e]) cout << "YES\n";
| ~~~~~~~~~~~~^
Main.cpp:108:21: warning: 'h_e' may be used uninitialized in this function [-Wmaybe-uninitialized]
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
6488 KB |
Output is correct |
2 |
Correct |
1 ms |
6492 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
6488 KB |
Output is correct |
2 |
Correct |
1 ms |
6492 KB |
Output is correct |
3 |
Correct |
1 ms |
6488 KB |
Output is correct |
4 |
Correct |
1 ms |
6616 KB |
Output is correct |
5 |
Correct |
1 ms |
6492 KB |
Output is correct |
6 |
Correct |
1 ms |
6492 KB |
Output is correct |
7 |
Correct |
1 ms |
6492 KB |
Output is correct |
8 |
Correct |
1 ms |
6492 KB |
Output is correct |
9 |
Correct |
1 ms |
6492 KB |
Output is correct |
10 |
Correct |
1 ms |
6488 KB |
Output is correct |
11 |
Correct |
1 ms |
6492 KB |
Output is correct |
12 |
Correct |
1 ms |
6492 KB |
Output is correct |
13 |
Correct |
1 ms |
6492 KB |
Output is correct |
14 |
Correct |
1 ms |
6492 KB |
Output is correct |
15 |
Correct |
1 ms |
6492 KB |
Output is correct |
16 |
Correct |
1 ms |
6492 KB |
Output is correct |
17 |
Correct |
1 ms |
6492 KB |
Output is correct |
18 |
Correct |
1 ms |
6492 KB |
Output is correct |
19 |
Correct |
1 ms |
6492 KB |
Output is correct |
20 |
Correct |
1 ms |
6492 KB |
Output is correct |
21 |
Correct |
1 ms |
6488 KB |
Output is correct |
22 |
Correct |
1 ms |
6492 KB |
Output is correct |
23 |
Correct |
1 ms |
6492 KB |
Output is correct |
24 |
Correct |
1 ms |
6492 KB |
Output is correct |
25 |
Correct |
1 ms |
6492 KB |
Output is correct |
26 |
Correct |
1 ms |
6492 KB |
Output is correct |
27 |
Correct |
1 ms |
6492 KB |
Output is correct |
28 |
Correct |
1 ms |
6492 KB |
Output is correct |
29 |
Correct |
1 ms |
6492 KB |
Output is correct |
30 |
Correct |
1 ms |
6492 KB |
Output is correct |
31 |
Correct |
1 ms |
6492 KB |
Output is correct |
32 |
Correct |
1 ms |
6492 KB |
Output is correct |
33 |
Correct |
1 ms |
6492 KB |
Output is correct |
34 |
Correct |
1 ms |
6492 KB |
Output is correct |
35 |
Correct |
1 ms |
6492 KB |
Output is correct |
36 |
Correct |
1 ms |
6492 KB |
Output is correct |
37 |
Correct |
1 ms |
6492 KB |
Output is correct |
38 |
Correct |
2 ms |
6600 KB |
Output is correct |
39 |
Correct |
1 ms |
6492 KB |
Output is correct |
40 |
Correct |
1 ms |
6492 KB |
Output is correct |
41 |
Correct |
1 ms |
6492 KB |
Output is correct |
42 |
Correct |
1 ms |
6492 KB |
Output is correct |
43 |
Correct |
1 ms |
6488 KB |
Output is correct |
44 |
Correct |
1 ms |
6492 KB |
Output is correct |
45 |
Correct |
1 ms |
6488 KB |
Output is correct |
46 |
Correct |
1 ms |
6488 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
6488 KB |
Output is correct |
2 |
Correct |
1 ms |
6492 KB |
Output is correct |
3 |
Correct |
1 ms |
6488 KB |
Output is correct |
4 |
Correct |
1 ms |
6616 KB |
Output is correct |
5 |
Correct |
1 ms |
6492 KB |
Output is correct |
6 |
Correct |
1 ms |
6492 KB |
Output is correct |
7 |
Correct |
1 ms |
6492 KB |
Output is correct |
8 |
Correct |
1 ms |
6492 KB |
Output is correct |
9 |
Correct |
1 ms |
6492 KB |
Output is correct |
10 |
Correct |
1 ms |
6488 KB |
Output is correct |
11 |
Correct |
1 ms |
6492 KB |
Output is correct |
12 |
Correct |
1 ms |
6492 KB |
Output is correct |
13 |
Correct |
1 ms |
6492 KB |
Output is correct |
14 |
Correct |
1 ms |
6492 KB |
Output is correct |
15 |
Correct |
1 ms |
6492 KB |
Output is correct |
16 |
Correct |
1 ms |
6492 KB |
Output is correct |
17 |
Correct |
1 ms |
6492 KB |
Output is correct |
18 |
Correct |
1 ms |
6492 KB |
Output is correct |
19 |
Correct |
1 ms |
6492 KB |
Output is correct |
20 |
Correct |
1 ms |
6492 KB |
Output is correct |
21 |
Correct |
1 ms |
6488 KB |
Output is correct |
22 |
Correct |
1 ms |
6492 KB |
Output is correct |
23 |
Correct |
1 ms |
6492 KB |
Output is correct |
24 |
Correct |
1 ms |
6492 KB |
Output is correct |
25 |
Correct |
1 ms |
6492 KB |
Output is correct |
26 |
Correct |
1 ms |
6492 KB |
Output is correct |
27 |
Correct |
1 ms |
6492 KB |
Output is correct |
28 |
Correct |
1 ms |
6492 KB |
Output is correct |
29 |
Correct |
1 ms |
6492 KB |
Output is correct |
30 |
Correct |
1 ms |
6492 KB |
Output is correct |
31 |
Correct |
1 ms |
6492 KB |
Output is correct |
32 |
Correct |
1 ms |
6492 KB |
Output is correct |
33 |
Correct |
1 ms |
6492 KB |
Output is correct |
34 |
Correct |
1 ms |
6492 KB |
Output is correct |
35 |
Correct |
1 ms |
6492 KB |
Output is correct |
36 |
Correct |
1 ms |
6492 KB |
Output is correct |
37 |
Correct |
1 ms |
6492 KB |
Output is correct |
38 |
Correct |
2 ms |
6600 KB |
Output is correct |
39 |
Correct |
1 ms |
6492 KB |
Output is correct |
40 |
Correct |
1 ms |
6492 KB |
Output is correct |
41 |
Correct |
1 ms |
6492 KB |
Output is correct |
42 |
Correct |
1 ms |
6492 KB |
Output is correct |
43 |
Correct |
1 ms |
6488 KB |
Output is correct |
44 |
Correct |
1 ms |
6492 KB |
Output is correct |
45 |
Correct |
1 ms |
6488 KB |
Output is correct |
46 |
Correct |
1 ms |
6488 KB |
Output is correct |
47 |
Correct |
1 ms |
6488 KB |
Output is correct |
48 |
Correct |
1 ms |
6748 KB |
Output is correct |
49 |
Correct |
1 ms |
6748 KB |
Output is correct |
50 |
Correct |
1 ms |
6748 KB |
Output is correct |
51 |
Correct |
1 ms |
6744 KB |
Output is correct |
52 |
Correct |
1 ms |
6748 KB |
Output is correct |
53 |
Correct |
1 ms |
6492 KB |
Output is correct |
54 |
Correct |
1 ms |
6748 KB |
Output is correct |
55 |
Correct |
1 ms |
6748 KB |
Output is correct |
56 |
Correct |
1 ms |
6748 KB |
Output is correct |
57 |
Correct |
1 ms |
6748 KB |
Output is correct |
58 |
Correct |
1 ms |
6748 KB |
Output is correct |
59 |
Correct |
1 ms |
6588 KB |
Output is correct |
60 |
Correct |
1 ms |
6748 KB |
Output is correct |
61 |
Correct |
2 ms |
6564 KB |
Output is correct |
62 |
Correct |
2 ms |
6748 KB |
Output is correct |
63 |
Correct |
2 ms |
6748 KB |
Output is correct |
64 |
Correct |
2 ms |
6744 KB |
Output is correct |
65 |
Correct |
1 ms |
6748 KB |
Output is correct |
66 |
Correct |
1 ms |
6748 KB |
Output is correct |
67 |
Correct |
1 ms |
6756 KB |
Output is correct |
68 |
Correct |
1 ms |
6748 KB |
Output is correct |
69 |
Correct |
1 ms |
6748 KB |
Output is correct |
70 |
Correct |
2 ms |
6748 KB |
Output is correct |
71 |
Correct |
1 ms |
6748 KB |
Output is correct |
72 |
Correct |
1 ms |
6748 KB |
Output is correct |
73 |
Correct |
2 ms |
6492 KB |
Output is correct |
74 |
Correct |
2 ms |
6488 KB |
Output is correct |
75 |
Correct |
1 ms |
6492 KB |
Output is correct |
76 |
Correct |
1 ms |
6748 KB |
Output is correct |
77 |
Correct |
1 ms |
6492 KB |
Output is correct |
78 |
Correct |
1 ms |
6536 KB |
Output is correct |
79 |
Correct |
1 ms |
6748 KB |
Output is correct |
80 |
Correct |
1 ms |
6492 KB |
Output is correct |
81 |
Correct |
1 ms |
6492 KB |
Output is correct |
82 |
Correct |
1 ms |
6492 KB |
Output is correct |
83 |
Correct |
1 ms |
6492 KB |
Output is correct |
84 |
Correct |
1 ms |
6492 KB |
Output is correct |
85 |
Correct |
1 ms |
6492 KB |
Output is correct |
86 |
Correct |
1 ms |
6620 KB |
Output is correct |
87 |
Correct |
2 ms |
6608 KB |
Output is correct |
88 |
Correct |
1 ms |
6748 KB |
Output is correct |
89 |
Correct |
1 ms |
6748 KB |
Output is correct |
90 |
Correct |
1 ms |
6492 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
6488 KB |
Output is correct |
2 |
Correct |
1 ms |
6492 KB |
Output is correct |
3 |
Correct |
1 ms |
6492 KB |
Output is correct |
4 |
Correct |
4 ms |
6796 KB |
Output is correct |
5 |
Correct |
4 ms |
6796 KB |
Output is correct |
6 |
Correct |
2 ms |
6492 KB |
Output is correct |
7 |
Correct |
4 ms |
6748 KB |
Output is correct |
8 |
Correct |
8 ms |
6744 KB |
Output is correct |
9 |
Correct |
1 ms |
6748 KB |
Output is correct |
10 |
Correct |
2 ms |
6744 KB |
Output is correct |
11 |
Correct |
1 ms |
6748 KB |
Output is correct |
12 |
Correct |
1 ms |
6748 KB |
Output is correct |
13 |
Correct |
1 ms |
6748 KB |
Output is correct |
14 |
Correct |
1 ms |
6748 KB |
Output is correct |
15 |
Correct |
3 ms |
6748 KB |
Output is correct |
16 |
Correct |
5 ms |
6748 KB |
Output is correct |
17 |
Correct |
3 ms |
6552 KB |
Output is correct |
18 |
Correct |
5 ms |
6796 KB |
Output is correct |
19 |
Correct |
4 ms |
6748 KB |
Output is correct |
20 |
Correct |
3 ms |
6796 KB |
Output is correct |
21 |
Correct |
4 ms |
6796 KB |
Output is correct |
22 |
Correct |
3 ms |
6748 KB |
Output is correct |
23 |
Correct |
3 ms |
6748 KB |
Output is correct |
24 |
Correct |
3 ms |
6748 KB |
Output is correct |
25 |
Correct |
3 ms |
6744 KB |
Output is correct |
26 |
Correct |
5 ms |
6748 KB |
Output is correct |
27 |
Correct |
3 ms |
6748 KB |
Output is correct |
28 |
Correct |
3 ms |
6748 KB |
Output is correct |
29 |
Correct |
3 ms |
6748 KB |
Output is correct |
30 |
Correct |
3 ms |
6748 KB |
Output is correct |
31 |
Correct |
3 ms |
6748 KB |
Output is correct |
32 |
Correct |
4 ms |
6748 KB |
Output is correct |
33 |
Correct |
5 ms |
6748 KB |
Output is correct |
34 |
Correct |
4 ms |
6748 KB |
Output is correct |
35 |
Correct |
3 ms |
6748 KB |
Output is correct |
36 |
Correct |
2 ms |
6748 KB |
Output is correct |
37 |
Correct |
2 ms |
6792 KB |
Output is correct |
38 |
Correct |
3 ms |
6876 KB |
Output is correct |
39 |
Correct |
2 ms |
7004 KB |
Output is correct |
40 |
Correct |
2 ms |
6748 KB |
Output is correct |
41 |
Correct |
3 ms |
7004 KB |
Output is correct |
42 |
Correct |
3 ms |
6748 KB |
Output is correct |
43 |
Correct |
4 ms |
6748 KB |
Output is correct |
44 |
Correct |
7 ms |
6892 KB |
Output is correct |
45 |
Correct |
3 ms |
6788 KB |
Output is correct |
46 |
Correct |
2 ms |
6876 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
6488 KB |
Output is correct |
2 |
Correct |
1 ms |
6492 KB |
Output is correct |
3 |
Correct |
1 ms |
6488 KB |
Output is correct |
4 |
Correct |
1 ms |
6616 KB |
Output is correct |
5 |
Correct |
1 ms |
6492 KB |
Output is correct |
6 |
Correct |
1 ms |
6492 KB |
Output is correct |
7 |
Correct |
1 ms |
6492 KB |
Output is correct |
8 |
Correct |
1 ms |
6492 KB |
Output is correct |
9 |
Correct |
1 ms |
6492 KB |
Output is correct |
10 |
Correct |
1 ms |
6488 KB |
Output is correct |
11 |
Correct |
1 ms |
6492 KB |
Output is correct |
12 |
Correct |
1 ms |
6492 KB |
Output is correct |
13 |
Correct |
1 ms |
6492 KB |
Output is correct |
14 |
Correct |
1 ms |
6492 KB |
Output is correct |
15 |
Correct |
1 ms |
6492 KB |
Output is correct |
16 |
Correct |
1 ms |
6492 KB |
Output is correct |
17 |
Correct |
1 ms |
6492 KB |
Output is correct |
18 |
Correct |
1 ms |
6492 KB |
Output is correct |
19 |
Correct |
1 ms |
6492 KB |
Output is correct |
20 |
Correct |
1 ms |
6492 KB |
Output is correct |
21 |
Correct |
1 ms |
6488 KB |
Output is correct |
22 |
Correct |
1 ms |
6492 KB |
Output is correct |
23 |
Correct |
1 ms |
6492 KB |
Output is correct |
24 |
Correct |
1 ms |
6492 KB |
Output is correct |
25 |
Correct |
1 ms |
6492 KB |
Output is correct |
26 |
Correct |
1 ms |
6492 KB |
Output is correct |
27 |
Correct |
1 ms |
6492 KB |
Output is correct |
28 |
Correct |
1 ms |
6492 KB |
Output is correct |
29 |
Correct |
1 ms |
6492 KB |
Output is correct |
30 |
Correct |
1 ms |
6492 KB |
Output is correct |
31 |
Correct |
1 ms |
6492 KB |
Output is correct |
32 |
Correct |
1 ms |
6492 KB |
Output is correct |
33 |
Correct |
1 ms |
6492 KB |
Output is correct |
34 |
Correct |
1 ms |
6492 KB |
Output is correct |
35 |
Correct |
1 ms |
6492 KB |
Output is correct |
36 |
Correct |
1 ms |
6492 KB |
Output is correct |
37 |
Correct |
1 ms |
6492 KB |
Output is correct |
38 |
Correct |
2 ms |
6600 KB |
Output is correct |
39 |
Correct |
1 ms |
6492 KB |
Output is correct |
40 |
Correct |
1 ms |
6492 KB |
Output is correct |
41 |
Correct |
1 ms |
6492 KB |
Output is correct |
42 |
Correct |
1 ms |
6492 KB |
Output is correct |
43 |
Correct |
1 ms |
6488 KB |
Output is correct |
44 |
Correct |
1 ms |
6492 KB |
Output is correct |
45 |
Correct |
1 ms |
6488 KB |
Output is correct |
46 |
Correct |
1 ms |
6488 KB |
Output is correct |
47 |
Correct |
1 ms |
6488 KB |
Output is correct |
48 |
Correct |
1 ms |
6748 KB |
Output is correct |
49 |
Correct |
1 ms |
6748 KB |
Output is correct |
50 |
Correct |
1 ms |
6748 KB |
Output is correct |
51 |
Correct |
1 ms |
6744 KB |
Output is correct |
52 |
Correct |
1 ms |
6748 KB |
Output is correct |
53 |
Correct |
1 ms |
6492 KB |
Output is correct |
54 |
Correct |
1 ms |
6748 KB |
Output is correct |
55 |
Correct |
1 ms |
6748 KB |
Output is correct |
56 |
Correct |
1 ms |
6748 KB |
Output is correct |
57 |
Correct |
1 ms |
6748 KB |
Output is correct |
58 |
Correct |
1 ms |
6748 KB |
Output is correct |
59 |
Correct |
1 ms |
6588 KB |
Output is correct |
60 |
Correct |
1 ms |
6748 KB |
Output is correct |
61 |
Correct |
2 ms |
6564 KB |
Output is correct |
62 |
Correct |
2 ms |
6748 KB |
Output is correct |
63 |
Correct |
2 ms |
6748 KB |
Output is correct |
64 |
Correct |
2 ms |
6744 KB |
Output is correct |
65 |
Correct |
1 ms |
6748 KB |
Output is correct |
66 |
Correct |
1 ms |
6748 KB |
Output is correct |
67 |
Correct |
1 ms |
6756 KB |
Output is correct |
68 |
Correct |
1 ms |
6748 KB |
Output is correct |
69 |
Correct |
1 ms |
6748 KB |
Output is correct |
70 |
Correct |
2 ms |
6748 KB |
Output is correct |
71 |
Correct |
1 ms |
6748 KB |
Output is correct |
72 |
Correct |
1 ms |
6748 KB |
Output is correct |
73 |
Correct |
2 ms |
6492 KB |
Output is correct |
74 |
Correct |
2 ms |
6488 KB |
Output is correct |
75 |
Correct |
1 ms |
6492 KB |
Output is correct |
76 |
Correct |
1 ms |
6748 KB |
Output is correct |
77 |
Correct |
1 ms |
6492 KB |
Output is correct |
78 |
Correct |
1 ms |
6536 KB |
Output is correct |
79 |
Correct |
1 ms |
6748 KB |
Output is correct |
80 |
Correct |
1 ms |
6492 KB |
Output is correct |
81 |
Correct |
1 ms |
6492 KB |
Output is correct |
82 |
Correct |
1 ms |
6492 KB |
Output is correct |
83 |
Correct |
1 ms |
6492 KB |
Output is correct |
84 |
Correct |
1 ms |
6492 KB |
Output is correct |
85 |
Correct |
1 ms |
6492 KB |
Output is correct |
86 |
Correct |
1 ms |
6620 KB |
Output is correct |
87 |
Correct |
2 ms |
6608 KB |
Output is correct |
88 |
Correct |
1 ms |
6748 KB |
Output is correct |
89 |
Correct |
1 ms |
6748 KB |
Output is correct |
90 |
Correct |
1 ms |
6492 KB |
Output is correct |
91 |
Correct |
1 ms |
6492 KB |
Output is correct |
92 |
Correct |
4 ms |
6796 KB |
Output is correct |
93 |
Correct |
4 ms |
6796 KB |
Output is correct |
94 |
Correct |
2 ms |
6492 KB |
Output is correct |
95 |
Correct |
4 ms |
6748 KB |
Output is correct |
96 |
Correct |
8 ms |
6744 KB |
Output is correct |
97 |
Correct |
1 ms |
6748 KB |
Output is correct |
98 |
Correct |
2 ms |
6744 KB |
Output is correct |
99 |
Correct |
1 ms |
6748 KB |
Output is correct |
100 |
Correct |
1 ms |
6748 KB |
Output is correct |
101 |
Correct |
1 ms |
6748 KB |
Output is correct |
102 |
Correct |
1 ms |
6748 KB |
Output is correct |
103 |
Correct |
3 ms |
6748 KB |
Output is correct |
104 |
Correct |
5 ms |
6748 KB |
Output is correct |
105 |
Correct |
3 ms |
6552 KB |
Output is correct |
106 |
Correct |
5 ms |
6796 KB |
Output is correct |
107 |
Correct |
4 ms |
6748 KB |
Output is correct |
108 |
Correct |
3 ms |
6796 KB |
Output is correct |
109 |
Correct |
4 ms |
6796 KB |
Output is correct |
110 |
Correct |
3 ms |
6748 KB |
Output is correct |
111 |
Correct |
3 ms |
6748 KB |
Output is correct |
112 |
Correct |
3 ms |
6748 KB |
Output is correct |
113 |
Correct |
3 ms |
6744 KB |
Output is correct |
114 |
Correct |
5 ms |
6748 KB |
Output is correct |
115 |
Correct |
3 ms |
6748 KB |
Output is correct |
116 |
Correct |
3 ms |
6748 KB |
Output is correct |
117 |
Correct |
3 ms |
6748 KB |
Output is correct |
118 |
Correct |
3 ms |
6748 KB |
Output is correct |
119 |
Correct |
3 ms |
6748 KB |
Output is correct |
120 |
Correct |
4 ms |
6748 KB |
Output is correct |
121 |
Correct |
5 ms |
6748 KB |
Output is correct |
122 |
Correct |
4 ms |
6748 KB |
Output is correct |
123 |
Correct |
3 ms |
6748 KB |
Output is correct |
124 |
Correct |
2 ms |
6748 KB |
Output is correct |
125 |
Correct |
2 ms |
6792 KB |
Output is correct |
126 |
Correct |
3 ms |
6876 KB |
Output is correct |
127 |
Correct |
2 ms |
7004 KB |
Output is correct |
128 |
Correct |
2 ms |
6748 KB |
Output is correct |
129 |
Correct |
3 ms |
7004 KB |
Output is correct |
130 |
Correct |
3 ms |
6748 KB |
Output is correct |
131 |
Correct |
4 ms |
6748 KB |
Output is correct |
132 |
Correct |
7 ms |
6892 KB |
Output is correct |
133 |
Correct |
3 ms |
6788 KB |
Output is correct |
134 |
Correct |
2 ms |
6876 KB |
Output is correct |
135 |
Correct |
3 ms |
6832 KB |
Output is correct |
136 |
Correct |
2 ms |
8796 KB |
Output is correct |
137 |
Correct |
2 ms |
8796 KB |
Output is correct |
138 |
Correct |
3 ms |
6620 KB |
Output is correct |
139 |
Correct |
3 ms |
8796 KB |
Output is correct |
140 |
Correct |
2 ms |
8848 KB |
Output is correct |
141 |
Correct |
1 ms |
6748 KB |
Output is correct |
142 |
Correct |
3 ms |
8796 KB |
Output is correct |
143 |
Correct |
2 ms |
8796 KB |
Output is correct |
144 |
Correct |
1 ms |
6492 KB |
Output is correct |
145 |
Correct |
2 ms |
8924 KB |
Output is correct |
146 |
Correct |
2 ms |
8796 KB |
Output is correct |
147 |
Correct |
18 ms |
8964 KB |
Output is correct |
148 |
Correct |
25 ms |
6748 KB |
Output is correct |
149 |
Correct |
23 ms |
6748 KB |
Output is correct |
150 |
Correct |
23 ms |
8980 KB |
Output is correct |
151 |
Correct |
21 ms |
8968 KB |
Output is correct |
152 |
Correct |
22 ms |
8796 KB |
Output is correct |
153 |
Correct |
23 ms |
8796 KB |
Output is correct |
154 |
Correct |
30 ms |
8796 KB |
Output is correct |
155 |
Correct |
20 ms |
8964 KB |
Output is correct |
156 |
Correct |
15 ms |
8980 KB |
Output is correct |
157 |
Correct |
23 ms |
8972 KB |
Output is correct |
158 |
Correct |
59 ms |
8796 KB |
Output is correct |
159 |
Correct |
60 ms |
8948 KB |
Output is correct |
160 |
Correct |
56 ms |
8972 KB |
Output is correct |
161 |
Correct |
63 ms |
8952 KB |
Output is correct |
162 |
Correct |
6 ms |
6748 KB |
Output is correct |
163 |
Correct |
7 ms |
6748 KB |
Output is correct |
164 |
Correct |
4 ms |
8796 KB |
Output is correct |
165 |
Correct |
4 ms |
6748 KB |
Output is correct |
166 |
Correct |
5 ms |
6796 KB |
Output is correct |
167 |
Correct |
4 ms |
6748 KB |
Output is correct |
168 |
Correct |
4 ms |
6796 KB |
Output is correct |
169 |
Correct |
5 ms |
6912 KB |
Output is correct |
170 |
Correct |
6 ms |
8964 KB |
Output is correct |
171 |
Correct |
8 ms |
6836 KB |
Output is correct |
172 |
Correct |
5 ms |
6896 KB |
Output is correct |
173 |
Correct |
5 ms |
6748 KB |
Output is correct |
174 |
Correct |
39 ms |
8948 KB |
Output is correct |
175 |
Correct |
37 ms |
8796 KB |
Output is correct |
176 |
Correct |
49 ms |
8796 KB |
Output is correct |
177 |
Correct |
58 ms |
8976 KB |
Output is correct |
178 |
Correct |
2 ms |
8796 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
6488 KB |
Output is correct |
2 |
Correct |
1 ms |
6492 KB |
Output is correct |
3 |
Correct |
1 ms |
6488 KB |
Output is correct |
4 |
Correct |
1 ms |
6616 KB |
Output is correct |
5 |
Correct |
1 ms |
6492 KB |
Output is correct |
6 |
Correct |
1 ms |
6492 KB |
Output is correct |
7 |
Correct |
1 ms |
6492 KB |
Output is correct |
8 |
Correct |
1 ms |
6492 KB |
Output is correct |
9 |
Correct |
1 ms |
6492 KB |
Output is correct |
10 |
Correct |
1 ms |
6488 KB |
Output is correct |
11 |
Correct |
1 ms |
6492 KB |
Output is correct |
12 |
Correct |
1 ms |
6492 KB |
Output is correct |
13 |
Correct |
1 ms |
6492 KB |
Output is correct |
14 |
Correct |
1 ms |
6492 KB |
Output is correct |
15 |
Correct |
1 ms |
6492 KB |
Output is correct |
16 |
Correct |
1 ms |
6492 KB |
Output is correct |
17 |
Correct |
1 ms |
6492 KB |
Output is correct |
18 |
Correct |
1 ms |
6492 KB |
Output is correct |
19 |
Correct |
1 ms |
6492 KB |
Output is correct |
20 |
Correct |
1 ms |
6492 KB |
Output is correct |
21 |
Correct |
1 ms |
6488 KB |
Output is correct |
22 |
Correct |
1 ms |
6492 KB |
Output is correct |
23 |
Correct |
1 ms |
6492 KB |
Output is correct |
24 |
Correct |
1 ms |
6492 KB |
Output is correct |
25 |
Correct |
1 ms |
6492 KB |
Output is correct |
26 |
Correct |
1 ms |
6492 KB |
Output is correct |
27 |
Correct |
1 ms |
6492 KB |
Output is correct |
28 |
Correct |
1 ms |
6492 KB |
Output is correct |
29 |
Correct |
1 ms |
6492 KB |
Output is correct |
30 |
Correct |
1 ms |
6492 KB |
Output is correct |
31 |
Correct |
1 ms |
6492 KB |
Output is correct |
32 |
Correct |
1 ms |
6492 KB |
Output is correct |
33 |
Correct |
1 ms |
6492 KB |
Output is correct |
34 |
Correct |
1 ms |
6492 KB |
Output is correct |
35 |
Correct |
1 ms |
6492 KB |
Output is correct |
36 |
Correct |
1 ms |
6492 KB |
Output is correct |
37 |
Correct |
1 ms |
6492 KB |
Output is correct |
38 |
Correct |
2 ms |
6600 KB |
Output is correct |
39 |
Correct |
1 ms |
6492 KB |
Output is correct |
40 |
Correct |
1 ms |
6492 KB |
Output is correct |
41 |
Correct |
1 ms |
6492 KB |
Output is correct |
42 |
Correct |
1 ms |
6492 KB |
Output is correct |
43 |
Correct |
1 ms |
6488 KB |
Output is correct |
44 |
Correct |
1 ms |
6492 KB |
Output is correct |
45 |
Correct |
1 ms |
6488 KB |
Output is correct |
46 |
Correct |
1 ms |
6488 KB |
Output is correct |
47 |
Correct |
1 ms |
6488 KB |
Output is correct |
48 |
Correct |
1 ms |
6748 KB |
Output is correct |
49 |
Correct |
1 ms |
6748 KB |
Output is correct |
50 |
Correct |
1 ms |
6748 KB |
Output is correct |
51 |
Correct |
1 ms |
6744 KB |
Output is correct |
52 |
Correct |
1 ms |
6748 KB |
Output is correct |
53 |
Correct |
1 ms |
6492 KB |
Output is correct |
54 |
Correct |
1 ms |
6748 KB |
Output is correct |
55 |
Correct |
1 ms |
6748 KB |
Output is correct |
56 |
Correct |
1 ms |
6748 KB |
Output is correct |
57 |
Correct |
1 ms |
6748 KB |
Output is correct |
58 |
Correct |
1 ms |
6748 KB |
Output is correct |
59 |
Correct |
1 ms |
6588 KB |
Output is correct |
60 |
Correct |
1 ms |
6748 KB |
Output is correct |
61 |
Correct |
2 ms |
6564 KB |
Output is correct |
62 |
Correct |
2 ms |
6748 KB |
Output is correct |
63 |
Correct |
2 ms |
6748 KB |
Output is correct |
64 |
Correct |
2 ms |
6744 KB |
Output is correct |
65 |
Correct |
1 ms |
6748 KB |
Output is correct |
66 |
Correct |
1 ms |
6748 KB |
Output is correct |
67 |
Correct |
1 ms |
6756 KB |
Output is correct |
68 |
Correct |
1 ms |
6748 KB |
Output is correct |
69 |
Correct |
1 ms |
6748 KB |
Output is correct |
70 |
Correct |
2 ms |
6748 KB |
Output is correct |
71 |
Correct |
1 ms |
6748 KB |
Output is correct |
72 |
Correct |
1 ms |
6748 KB |
Output is correct |
73 |
Correct |
2 ms |
6492 KB |
Output is correct |
74 |
Correct |
2 ms |
6488 KB |
Output is correct |
75 |
Correct |
1 ms |
6492 KB |
Output is correct |
76 |
Correct |
1 ms |
6748 KB |
Output is correct |
77 |
Correct |
1 ms |
6492 KB |
Output is correct |
78 |
Correct |
1 ms |
6536 KB |
Output is correct |
79 |
Correct |
1 ms |
6748 KB |
Output is correct |
80 |
Correct |
1 ms |
6492 KB |
Output is correct |
81 |
Correct |
1 ms |
6492 KB |
Output is correct |
82 |
Correct |
1 ms |
6492 KB |
Output is correct |
83 |
Correct |
1 ms |
6492 KB |
Output is correct |
84 |
Correct |
1 ms |
6492 KB |
Output is correct |
85 |
Correct |
1 ms |
6492 KB |
Output is correct |
86 |
Correct |
1 ms |
6620 KB |
Output is correct |
87 |
Correct |
2 ms |
6608 KB |
Output is correct |
88 |
Correct |
1 ms |
6748 KB |
Output is correct |
89 |
Correct |
1 ms |
6748 KB |
Output is correct |
90 |
Correct |
1 ms |
6492 KB |
Output is correct |
91 |
Correct |
1 ms |
6492 KB |
Output is correct |
92 |
Correct |
4 ms |
6796 KB |
Output is correct |
93 |
Correct |
4 ms |
6796 KB |
Output is correct |
94 |
Correct |
2 ms |
6492 KB |
Output is correct |
95 |
Correct |
4 ms |
6748 KB |
Output is correct |
96 |
Correct |
8 ms |
6744 KB |
Output is correct |
97 |
Correct |
1 ms |
6748 KB |
Output is correct |
98 |
Correct |
2 ms |
6744 KB |
Output is correct |
99 |
Correct |
1 ms |
6748 KB |
Output is correct |
100 |
Correct |
1 ms |
6748 KB |
Output is correct |
101 |
Correct |
1 ms |
6748 KB |
Output is correct |
102 |
Correct |
1 ms |
6748 KB |
Output is correct |
103 |
Correct |
3 ms |
6748 KB |
Output is correct |
104 |
Correct |
5 ms |
6748 KB |
Output is correct |
105 |
Correct |
3 ms |
6552 KB |
Output is correct |
106 |
Correct |
5 ms |
6796 KB |
Output is correct |
107 |
Correct |
4 ms |
6748 KB |
Output is correct |
108 |
Correct |
3 ms |
6796 KB |
Output is correct |
109 |
Correct |
4 ms |
6796 KB |
Output is correct |
110 |
Correct |
3 ms |
6748 KB |
Output is correct |
111 |
Correct |
3 ms |
6748 KB |
Output is correct |
112 |
Correct |
3 ms |
6748 KB |
Output is correct |
113 |
Correct |
3 ms |
6744 KB |
Output is correct |
114 |
Correct |
5 ms |
6748 KB |
Output is correct |
115 |
Correct |
3 ms |
6748 KB |
Output is correct |
116 |
Correct |
3 ms |
6748 KB |
Output is correct |
117 |
Correct |
3 ms |
6748 KB |
Output is correct |
118 |
Correct |
3 ms |
6748 KB |
Output is correct |
119 |
Correct |
3 ms |
6748 KB |
Output is correct |
120 |
Correct |
4 ms |
6748 KB |
Output is correct |
121 |
Correct |
5 ms |
6748 KB |
Output is correct |
122 |
Correct |
4 ms |
6748 KB |
Output is correct |
123 |
Correct |
3 ms |
6748 KB |
Output is correct |
124 |
Correct |
2 ms |
6748 KB |
Output is correct |
125 |
Correct |
2 ms |
6792 KB |
Output is correct |
126 |
Correct |
3 ms |
6876 KB |
Output is correct |
127 |
Correct |
2 ms |
7004 KB |
Output is correct |
128 |
Correct |
2 ms |
6748 KB |
Output is correct |
129 |
Correct |
3 ms |
7004 KB |
Output is correct |
130 |
Correct |
3 ms |
6748 KB |
Output is correct |
131 |
Correct |
4 ms |
6748 KB |
Output is correct |
132 |
Correct |
7 ms |
6892 KB |
Output is correct |
133 |
Correct |
3 ms |
6788 KB |
Output is correct |
134 |
Correct |
2 ms |
6876 KB |
Output is correct |
135 |
Correct |
3 ms |
6832 KB |
Output is correct |
136 |
Correct |
2 ms |
8796 KB |
Output is correct |
137 |
Correct |
2 ms |
8796 KB |
Output is correct |
138 |
Correct |
3 ms |
6620 KB |
Output is correct |
139 |
Correct |
3 ms |
8796 KB |
Output is correct |
140 |
Correct |
2 ms |
8848 KB |
Output is correct |
141 |
Correct |
1 ms |
6748 KB |
Output is correct |
142 |
Correct |
3 ms |
8796 KB |
Output is correct |
143 |
Correct |
2 ms |
8796 KB |
Output is correct |
144 |
Correct |
1 ms |
6492 KB |
Output is correct |
145 |
Correct |
2 ms |
8924 KB |
Output is correct |
146 |
Correct |
2 ms |
8796 KB |
Output is correct |
147 |
Correct |
18 ms |
8964 KB |
Output is correct |
148 |
Correct |
25 ms |
6748 KB |
Output is correct |
149 |
Correct |
23 ms |
6748 KB |
Output is correct |
150 |
Correct |
23 ms |
8980 KB |
Output is correct |
151 |
Correct |
21 ms |
8968 KB |
Output is correct |
152 |
Correct |
22 ms |
8796 KB |
Output is correct |
153 |
Correct |
23 ms |
8796 KB |
Output is correct |
154 |
Correct |
30 ms |
8796 KB |
Output is correct |
155 |
Correct |
20 ms |
8964 KB |
Output is correct |
156 |
Correct |
15 ms |
8980 KB |
Output is correct |
157 |
Correct |
23 ms |
8972 KB |
Output is correct |
158 |
Correct |
59 ms |
8796 KB |
Output is correct |
159 |
Correct |
60 ms |
8948 KB |
Output is correct |
160 |
Correct |
56 ms |
8972 KB |
Output is correct |
161 |
Correct |
63 ms |
8952 KB |
Output is correct |
162 |
Correct |
6 ms |
6748 KB |
Output is correct |
163 |
Correct |
7 ms |
6748 KB |
Output is correct |
164 |
Correct |
4 ms |
8796 KB |
Output is correct |
165 |
Correct |
4 ms |
6748 KB |
Output is correct |
166 |
Correct |
5 ms |
6796 KB |
Output is correct |
167 |
Correct |
4 ms |
6748 KB |
Output is correct |
168 |
Correct |
4 ms |
6796 KB |
Output is correct |
169 |
Correct |
5 ms |
6912 KB |
Output is correct |
170 |
Correct |
6 ms |
8964 KB |
Output is correct |
171 |
Correct |
8 ms |
6836 KB |
Output is correct |
172 |
Correct |
5 ms |
6896 KB |
Output is correct |
173 |
Correct |
5 ms |
6748 KB |
Output is correct |
174 |
Correct |
39 ms |
8948 KB |
Output is correct |
175 |
Correct |
37 ms |
8796 KB |
Output is correct |
176 |
Correct |
49 ms |
8796 KB |
Output is correct |
177 |
Correct |
58 ms |
8976 KB |
Output is correct |
178 |
Correct |
2 ms |
8796 KB |
Output is correct |
179 |
Correct |
83 ms |
11380 KB |
Output is correct |
180 |
Correct |
23 ms |
15088 KB |
Output is correct |
181 |
Correct |
25 ms |
14972 KB |
Output is correct |
182 |
Correct |
5 ms |
11352 KB |
Output is correct |
183 |
Correct |
18 ms |
14824 KB |
Output is correct |
184 |
Correct |
20 ms |
14780 KB |
Output is correct |
185 |
Correct |
18 ms |
14272 KB |
Output is correct |
186 |
Correct |
20 ms |
14904 KB |
Output is correct |
187 |
Correct |
18 ms |
14860 KB |
Output is correct |
188 |
Correct |
10 ms |
14028 KB |
Output is correct |
189 |
Correct |
17 ms |
14932 KB |
Output is correct |
190 |
Correct |
27 ms |
14992 KB |
Output is correct |
191 |
Correct |
1146 ms |
14812 KB |
Output is correct |
192 |
Correct |
1169 ms |
14988 KB |
Output is correct |
193 |
Correct |
1223 ms |
14832 KB |
Output is correct |
194 |
Correct |
1375 ms |
15020 KB |
Output is correct |
195 |
Correct |
1316 ms |
15188 KB |
Output is correct |
196 |
Correct |
1327 ms |
15020 KB |
Output is correct |
197 |
Correct |
1332 ms |
15216 KB |
Output is correct |
198 |
Correct |
1361 ms |
15016 KB |
Output is correct |
199 |
Correct |
1301 ms |
13740 KB |
Output is correct |
200 |
Correct |
750 ms |
13744 KB |
Output is correct |
201 |
Correct |
740 ms |
13744 KB |
Output is correct |
202 |
Execution timed out |
1572 ms |
13700 KB |
Time limit exceeded |
203 |
Halted |
0 ms |
0 KB |
- |