# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
140184 | 2019-08-02T08:22:10 Z | bazsi700 | Mechanical Doll (IOI18_doll) | C++14 | 3 ms | 332 KB |
#include <bits/stdc++.h> #include "doll.h" using namespace std; #define MOD 1000000007 #define ll long long int #define vi vector<int> #define vii vector< vector<int> > #define PI 3.1415926535897932384626433832795 #define INF 9223372036854775807LL #define hashA 1257958787 #define hashB 1539500609 #define endl "\n" void create_circuit(int m, vector<int> A) { vector<int> C(m+1); int n = A.size(); vector<int> X (25); vector<int> Y (25); C[0] = -1; C[1] = -1; int last = 0; X[0] = 1; for(int i = 1; i < 25; i++) { X[i] = -1; Y[i] = -(i+2); } Y[0] = -2; Y[24] = 0; for(int i = 23; i >= 0; i--) { int x = (1<<i); if(n >= x) { n-=x; } else { swap(X[-(i+1)],Y[-(i+1)]); } } answer(C,X,Y); }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 3 ms | 332 KB | Execution killed with signal 6 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 3 ms | 332 KB | Execution killed with signal 6 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 3 ms | 332 KB | Execution killed with signal 6 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 332 KB | Execution killed with signal 6 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 2 ms | 332 KB | Execution killed with signal 6 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 2 ms | 332 KB | Execution killed with signal 6 |
2 | Halted | 0 ms | 0 KB | - |