# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
1019264 |
2024-07-10T16:30:21 Z |
rockstar |
Kocka (COCI18_kocka) |
C++17 |
|
24 ms |
4340 KB |
#include <bits/stdc++.h>
using namespace std;
int main() {
cin.tie(nullptr)->sync_with_stdio(false);
int n;
cin >> n;
vector<int> l(n), r(n), d(n), u(n);
for (int &i : l) cin >> i;
for (int &i : r) cin >> i;
for (int &i : u) cin >> i;
for (int &i : d) cin >> i;
bool ok = true;
for (int i = 0; i < n; ++i)
if ((l[i] == -1 && r[i] != -1) || (l[i] != -1 && r[i] == -1) || (u[i] == -1 && d[i] != -1) || (u[i] != -1 && d[i] == -1))
ok = false;
cout << (ok ? "DA" : "NE");
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
344 KB |
Output is correct |
2 |
Correct |
1 ms |
348 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
1 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
348 KB |
Output is correct |
6 |
Correct |
1 ms |
348 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
1 ms |
348 KB |
Output is correct |
2 |
Correct |
1 ms |
460 KB |
Output is correct |
3 |
Correct |
1 ms |
348 KB |
Output is correct |
4 |
Correct |
1 ms |
348 KB |
Output is correct |
5 |
Correct |
1 ms |
344 KB |
Output is correct |
6 |
Correct |
0 ms |
344 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
21 ms |
3816 KB |
Output is correct |
2 |
Correct |
22 ms |
4312 KB |
Output is correct |
3 |
Correct |
21 ms |
4184 KB |
Output is correct |
4 |
Correct |
15 ms |
3160 KB |
Output is correct |
5 |
Correct |
20 ms |
4188 KB |
Output is correct |
6 |
Correct |
20 ms |
4324 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
20 ms |
3928 KB |
Output is correct |
2 |
Correct |
16 ms |
3164 KB |
Output is correct |
3 |
Correct |
20 ms |
4188 KB |
Output is correct |
4 |
Correct |
18 ms |
3164 KB |
Output is correct |
5 |
Correct |
22 ms |
4188 KB |
Output is correct |
6 |
Correct |
21 ms |
3932 KB |
Output is correct |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
21 ms |
3676 KB |
Output is correct |
2 |
Correct |
15 ms |
3164 KB |
Output is correct |
3 |
Correct |
21 ms |
4324 KB |
Output is correct |
4 |
Correct |
22 ms |
4176 KB |
Output is correct |
5 |
Correct |
24 ms |
4340 KB |
Output is correct |
6 |
Correct |
18 ms |
3164 KB |
Output is correct |