QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#774465#9784. Donkey and Puss in Bootsucup-team5697#WA 0ms3692kbC++14565b2024-11-23 13:18:282024-11-23 13:18:28

Judging History

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

  • [2024-11-23 13:18:28]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3692kb
  • [2024-11-23 13:18:28]
  • 提交

answer

#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <vector>
#include <map>
#define mems(x, v) memset(x, v, sizeof x)
#define mcpy(x, y) memcpy(x, y, sizeof x)
using namespace std;
typedef pair <int, int> pii;
typedef long long ll;
typedef unsigned long long ull;
typedef long double wisdom;

map <int, int> cnt;
int main() {
	int n; scanf("%d", &n);
	for (int i = 1, x; i <= n; i++) scanf("%d", &x), cnt[x]++;
	for (auto [x, y] : cnt) if (y & 1) return puts("Donkey"), 0; puts("Puss in Boots");
	return 0;
}

详细

Test #1:

score: 100
Accepted
time: 0ms
memory: 3568kb

input:

2
2 2

output:

Puss in Boots

result:

ok single line: 'Puss in Boots'

Test #2:

score: 0
Accepted
time: 0ms
memory: 3612kb

input:

4
0 47 0 0

output:

Donkey

result:

ok single line: 'Donkey'

Test #3:

score: 0
Accepted
time: 0ms
memory: 3692kb

input:

4
0 47 0 0

output:

Donkey

result:

ok single line: 'Donkey'

Test #4:

score: -100
Wrong Answer
time: 0ms
memory: 3612kb

input:

10
5 7 3 0 2 0 0 1 0 0

output:

Donkey

result:

wrong answer 1st lines differ - expected: 'Puss in Boots', found: 'Donkey'