# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
238942 | 2020-06-13T16:50:19 Z | dolphingarlic | Balloons (CEOI11_bal) | C++14 | 178 ms | 7288 KB |
#include <bits/stdc++.h> int main() { int n; std::stack<std::pair<double, double>> stck; scanf("%d", &n); while (n--) { double x, r; scanf("%lf %lf", &x, &r); while (stck.size()) { r = std::min(r, (x - stck.top().first) * (x - stck.top().first) / stck.top().second / 4); if (r > stck.top().second) stck.pop(); else break; } stck.push({x, r}); printf("%.3f\n", r); } return 0; }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 5 ms | 256 KB | 10 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 5 ms | 384 KB | 2 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 5 ms | 256 KB | 505 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 6 ms | 384 KB | 2000 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 22 ms | 768 KB | 20000 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 49 ms | 1656 KB | 50000 numbers |
2 | Correct | 47 ms | 2044 KB | 49912 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 95 ms | 2808 KB | 100000 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 111 ms | 3192 KB | 115362 numbers |
2 | Correct | 93 ms | 4348 KB | 119971 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 145 ms | 4088 KB | 154271 numbers |
2 | Correct | 154 ms | 7032 KB | 200000 numbers |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 178 ms | 4600 KB | 200000 numbers |
2 | Correct | 162 ms | 7288 KB | 199945 numbers |