QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#502314 | #9156. 百万富翁 | nhuang685# | 0 | 0ms | 23760kb | C++20 | 526b | 2024-08-03 03:34:17 | 2024-08-03 03:34:18 |
Judging History
answer
#include "richest.h"
#include <bits/stdc++.h>
int richest(int N, int T, int S) {
std::vector<int> a, b;
for (int i = 0; i < N; ++i) {
for (int j = 1; j < N; ++j) {
a.push_back(i);
b.push_back(j);
}
}
std::vector<int> res = ask(a, b);
std::vector<int> cnt(N);
for (int i = 0; i < N; ++i) {
++cnt[res[i]];
}
for (int i = 0; i < N; ++i) {
if (cnt[i] == N) {
return i;
}
}
assert(false);
}
Details
Tip: Click on the bar to expand more detailed information
Pretests
Pretest #1:
score: 0
Wrong Answer
time: 0ms
memory: 23684kb
input:
1000 1 499500 957319859
output:
Too many total elements in queries 1469670942222006797 0.000000 6906350380861515327
result:
points 0.0 Too many total elements in queries
Pretest #2:
score: 0
Memory Limit Exceeded
input:
1000000 20 2000000 29091473
output:
Unauthorized output
result:
Final Tests
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 23760kb
input:
1000 1 499500 957319857
output:
Too many total elements in queries 1469670942222006797 0.000000 6906350380861515327
result:
points 0.0 Too many total elements in queries
Test #2:
score: 0
Memory Limit Exceeded
input:
1000000 20 2000000 29091471
output:
Unauthorized output