QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#629388 | #9168. Square Locator | chie4 | WA | 0ms | 3568kb | C++14 | 554b | 2024-10-11 11:03:20 | 2024-10-11 11:03:21 |
Judging History
answer
#include <cmath>
#include <cstdlib>
#include <iostream>
long long acb(long long c, long long b) { return sqrt(c - b); }
int main() {
unsigned long long oa, ob, oc, od;
std::cin >> oa >> ob >> oc >> od;
oa = sqrt(oa);
long long cx, cy, bx, dx;
cx = (ob - od) / (2 * oa);
cx = std::abs(cx);
cy = acb(oc, cx * cx);
bx = (oa - cy - cx) / -2;
dx = cx - bx;
std::cout << oa << " " << bx << " " << acb(ob, bx * bx) << " " << cx << " "
<< cy << " " << dx << " " << acb(od, dx * dx);
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 3568kb
input:
36 5 10 41
output:
6 0 2 1537228672809129298 2863311530 1537228672809129298 2863311530
result:
wrong answer Integer parameter [name=C_x] equals to 1537228672809129298, violates the range [-10^9, 10^9]