# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
574508 | 2022-06-08T16:15:04 Z | Lobo | Pictionary (COCI18_pictionary) | C++17 | 1 ms | 512 KB |
#include<bits/stdc++.h> using namespace std; int main(){ int t; cin >> t; while(t--){ int a, b, k; cin >> a >> b >> k; int g = gcd(a, b); int l, i; while(!g%l){ if(i&1) l = g/k; if(!(i&1)) l = (g+k-1)/k; i++; } int lol = g/l; int ans = k-lol+1; cout << ans << '\n'; } }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 512 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 440 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 384 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 340 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 468 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 340 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 460 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 500 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Runtime error | 1 ms | 340 KB | Execution killed with signal 8 |
2 | Halted | 0 ms | 0 KB | - |