QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#129697 | #4545. Triangle Game | batrr# | AC ✓ | 12ms | 3468kb | C++17 | 1.2kb | 2023-07-22 22:13:36 | 2023-07-22 22:13:40 |
Judging History
answer
#include <bits/stdc++.h>
#define f first
#define s second
#define pb push_back
#define mp make_pair
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<long long, long long> pll;
const int N = 300500, inf = 1e9, mod = 1000000007;
const ll INF = 1e18;
int sum(int a, int b) {
a += b;
if (a >= mod)
a -= mod;
return a;
}
int sub(int a, int b) {
a -= b;
if (a < 0)
a += mod;
return a;
}
int mult(int a, int b) {
return 1ll * a * b % mod;
}
int bp(int a, int b) {
int res = 1;
while (b) {
if (b & 1)
res = mult(res, a);
a = mult(a, a);
b >>= 1;
}
return res;
}
int inv(int x) {
return bp(x, mod - 2);
}
void solve() {
ll a, b, c;
cin >> a >> b >> c;
a--, b--, c--;
if ((a^b^c)==0) cout << "Lose\n";
else cout << "Win\n";
}
int main() {
#ifdef DEBUG
freopen("input.txt", "r", stdin);
#endif
ios_base::sync_with_stdio(false);
int t = 1;
cin >> t;
for (int i = 1; i <= t; i++) {
// cout << "Case #" << i << endl;
solve();
}
}
詳細信息
Test #1:
score: 100
Accepted
time: 12ms
memory: 3468kb
input:
10000 1 1 1 1 2 2 1 3 3 1 4 4 1 5 5 1 6 6 1 7 7 1 8 8 1 9 9 1 10 10 1 11 11 1 12 12 1 13 13 1 14 14 1 15 15 1 16 16 1 17 17 1 18 18 1 19 19 1 20 20 2 1 2 2 2 1 2 2 2 2 2 3 2 3 2 2 3 3 2 3 4 2 4 3 2 4 4 2 4 5 2 5 4 2 5 5 2 5 6 2 6 5 2 6 6 2 6 7 2 7 6 2 7 7 2 7 8 2 8 7 2 8 8 2 8 9 2 9 8 2 9 9 2 9 10 2...
output:
Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Lose Win Win Win Win Lose Lose Win Win Win Win Lose Lose Win Win Win Win Lose Lose Win Win Win Win Lose Lose Win Win Win Win Lose Lose Win Win Win Win Lose Lose Win Win Win Win Lose Lose Win Win ...
result:
ok 10000 lines