QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#153277#6859. Alice Gameneko_nyaaWA 0ms3672kbC++23728b2023-08-29 20:00:462023-08-29 20:00:46

Judging History

你现在查看的是最新测评结果

  • [2023-08-29 20:00:46]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3672kb
  • [2023-08-29 20:00:46]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;

#define int long long
const int M = 1000000007;
int modpow(int n, int k) {
	int ans = 1;
	while (k) {
		if (k % 2) ans = (ans*n) % M;
		n = (n*n) % M; k /= 2;
	}
	return ans;
}

int c4(int n) {
	int p = n*(n-1)*(n-2)*(n-3) % M;
	int q = 1*2*3*4;
	return p*modpow(q, M-2) % M;
}

int c2(int n) {
	int p = n*(n-1);
	int q = 1*2;
	return p*modpow(q, M-2) % M;
}

typedef bitset<1000> bs;

void solve() {
	int k, n; cin >> k >> n;
	if (n <= k || (k % 2) == (n % 2)) {
		cout << "Alice\n";
	} else {
		cout << "Bob\n";
	}
}

signed main() {
	ios::sync_with_stdio(0); cin.tie(0);

	int t; cin >> t;
	while (t--) {
		solve();
	}

	return 0;
}

詳細信息

Test #1:

score: 0
Wrong Answer
time: 0ms
memory: 3672kb

input:

10000
215030 4437195
8215193 41075968
9100231 94335691
1846348 75360383
5022266 33559435
3346837 83705658
3209595 91853022
6760646 72650429
1861672 46541813
847955 91391745
6760979 91894780
8926014 2897123
8789221 17902247
2935002 27259386
6708849 33788122
2811931 29235487
1067245 624896
7134584 576...

output:

Bob
Bob
Alice
Bob
Bob
Bob
Bob
Bob
Bob
Alice
Bob
Alice
Alice
Alice
Bob
Alice
Alice
Bob
Bob
Bob
Alice
Bob
Alice
Alice
Bob
Bob
Bob
Alice
Bob
Bob
Alice
Alice
Bob
Alice
Alice
Bob
Alice
Alice
Alice
Alice
Alice
Bob
Bob
Bob
Alice
Bob
Alice
Alice
Bob
Alice
Alice
Alice
Bob
Bob
Alice
Bob
Bob
Bob
Bob
Alice
Bob
...

result:

wrong answer 1st lines differ - expected: 'Alice', found: 'Bob'