QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#239188 | #7637. Exactly Three Neighbors | ucup-team859# | WA | 1ms | 3396kb | C++17 | 710b | 2023-11-04 19:05:37 | 2023-11-04 19:05:39 |
Judging History
answer
#include <bits/stdc++.h>
#include <time.h>
#define lsb(x) (x & (-x))
using ull = unsigned long long;
using ll = long long;
using namespace std;
int main() {
#ifdef LOCAL
ifstream cin("test.in");
ofstream cout("test.out");
#endif
int x, y;
cin >> x >> y;
if (x == 0) {
cout << "1 1\n.\n";
}
else {
if (x == y || (2 * y) % x != 0) {
cout << "-1 -1\n";
}
else {
int t = 2 * y / x;
cout << "1 " << t << '\n';
cout << "##";
for (int i = 2; i < t; i++) {
cout << '.';
}
cout << '\n';
}
}
return 0;
}
详细
Test #1:
score: 100
Accepted
time: 1ms
memory: 3396kb
input:
2 3
output:
1 3 ##.
result:
ok good solution
Test #2:
score: 0
Accepted
time: 0ms
memory: 3340kb
input:
1 1
output:
-1 -1
result:
ok no solution
Test #3:
score: -100
Wrong Answer
time: 0ms
memory: 3364kb
input:
3 4
output:
-1 -1
result:
wrong answer you didn't find a solution but jury did