# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
845753 | 2023-09-06T15:15:12 Z | vjudge1 | Konstrukcija (COCI20_konstrukcija) | C++17 | 1 ms | 600 KB |
#include <bits/stdc++.h> #define int long long using namespace std; int MX = 64; void solve(void){ int x; cin >> x; x = -x; /* * 7k+2 7k+3 <- 7k+4 * * 7k+5 7k+6 7k+7 <- 7k+8 * * */ cout << 7*MX+23 << " " << 15*MX + 14 - 15<< "\n"; cout << "1 2\n2 3\n2 4\n3 6\n3 7\n3 8\n4 6\n4 7\n4 8\n"; for(int i=1; i<MX; i++){ cout << 7*i-2 +1 << " " << 7*i+2 +1 << "\n"; cout << 7*i-2 +1 << " " << 7*i+3 +1 << "\n"; cout << 7*i-1 +1 << " " << 7*i+2 +1 << "\n"; cout << 7*i-1 +1 << " " << 7*i+3 +1 << "\n"; cout << 7*i+0 +1 << " " << 7*i+2 +1 << "\n"; cout << 7*i+0 +1 << " " << 7*i+3 +1 << "\n"; cout << 7*i+3 +1 << " " << 7*i+5 +1 << "\n"; cout << 7*i+3 +1 << " " << 7*i+6 +1 << "\n"; cout << 7*i+3 +1 << " " << 7*i+7 +1 << "\n"; cout << 7*i+2 +1 << " " << 7*i+5 +1 << "\n"; cout << 7*i+2 +1 << " " << 7*i+6 +1 << "\n"; cout << 7*i+2 +1 << " " << 7*i+7 +1 << "\n"; if(x < 0){ cout << 7*i+4 +1 << " " << 7*i+2 +1 << "\n"; cout << 7*i+4 +1 << " " << 7*i+3 +1 << "\n"; }else{ cout << 7*i+8 +1 << " " << 7*i+5 +1 << "\n"; cout << 7*i+8 +1 << " " << 7*i+6 +1 << "\n"; } } int zero = 7*MX + 20; cout << 7*(MX) + 5 << " " << 7*MX+23 << "\n"; cout << 7*MX-1 << " " << 7*MX+23 << "\n"; cout << 7*MX+0 << " " << 7*MX+23 << "\n"; cout << 7*MX+1 << " " << 7*MX+23 << "\n"; int shift = 2; if(x<0){ shift += 3; x = -x; } for(int i=0; i<MX; i++){ int point = (MX-i)*7+shift; if( (x>>i)%2 == 0 ) point = (MX-i)*7; cout << "1 " << point << "\n"; } } signed main(){ int t=1; // cin >> t; while(t--) solve(); return 0; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 344 KB | Correct. |
2 | Correct | 1 ms | 348 KB | Correct. |
3 | Correct | 1 ms | 348 KB | Correct. |
4 | Correct | 0 ms | 348 KB | Correct. |
5 | Correct | 0 ms | 600 KB | Correct. |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 348 KB | Correct. |
2 | Correct | 1 ms | 344 KB | Correct. |
3 | Correct | 0 ms | 348 KB | Correct. |
4 | Correct | 0 ms | 348 KB | Correct. |
5 | Correct | 0 ms | 348 KB | Correct. |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 344 KB | Correct. |
2 | Correct | 1 ms | 348 KB | Correct. |
3 | Correct | 1 ms | 348 KB | Correct. |
4 | Correct | 0 ms | 348 KB | Correct. |
5 | Correct | 0 ms | 600 KB | Correct. |
6 | Correct | 0 ms | 348 KB | Correct. |
7 | Correct | 1 ms | 344 KB | Correct. |
8 | Correct | 0 ms | 348 KB | Correct. |
9 | Correct | 0 ms | 348 KB | Correct. |
10 | Correct | 0 ms | 348 KB | Correct. |
11 | Correct | 0 ms | 348 KB | Correct. |
12 | Correct | 0 ms | 348 KB | Correct. |
13 | Correct | 1 ms | 348 KB | Correct. |
14 | Correct | 1 ms | 348 KB | Correct. |
15 | Correct | 0 ms | 348 KB | Correct. |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 344 KB | Correct. |
2 | Correct | 1 ms | 348 KB | Correct. |
3 | Correct | 1 ms | 348 KB | Correct. |
4 | Correct | 0 ms | 348 KB | Correct. |
5 | Correct | 0 ms | 600 KB | Correct. |
6 | Correct | 0 ms | 348 KB | Correct. |
7 | Correct | 1 ms | 344 KB | Correct. |
8 | Correct | 0 ms | 348 KB | Correct. |
9 | Correct | 0 ms | 348 KB | Correct. |
10 | Correct | 0 ms | 348 KB | Correct. |
11 | Correct | 0 ms | 348 KB | Correct. |
12 | Correct | 0 ms | 348 KB | Correct. |
13 | Correct | 1 ms | 348 KB | Correct. |
14 | Correct | 1 ms | 348 KB | Correct. |
15 | Correct | 0 ms | 348 KB | Correct. |
16 | Correct | 0 ms | 348 KB | Correct. |
17 | Correct | 0 ms | 348 KB | Correct. |
18 | Correct | 1 ms | 348 KB | Correct. |
19 | Correct | 0 ms | 344 KB | Correct. |
20 | Correct | 0 ms | 348 KB | Correct. |
21 | Correct | 1 ms | 348 KB | Correct. |
22 | Correct | 0 ms | 348 KB | Correct. |
23 | Correct | 0 ms | 348 KB | Correct. |
24 | Correct | 0 ms | 348 KB | Correct. |
25 | Correct | 0 ms | 348 KB | Correct. |
26 | Correct | 0 ms | 348 KB | Correct. |
27 | Correct | 1 ms | 348 KB | Correct. |