QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#129243 | #6740. Function | Nicolas125841 | WA | 105ms | 91400kb | C++17 | 697b | 2023-07-22 11:39:48 | 2023-07-22 11:39:50 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const ll mod = 998244353;
const int N = 20210926;
const int SB = 32;
vector<int> lp(N+1), pr;
void prep(){
for (int i=2; i <= N; ++i) {
if (lp[i] == 0) {
lp[i] = i;
pr.push_back(i);
}
for (int j = 0; i * pr[j] <= N; ++j) {
lp[i * pr[j]] = pr[j];
if (pr[j] == lp[i]) {
break;
}
}
}
}
int main(){
prep();
int n;
cin >> n;
ll ans = 0;
//for(int i = 1; i <= n; i++){
// ans += pref[i] - pref[i-1];
//}
cout << ans << "\n";
}
詳細信息
Test #1:
score: 0
Wrong Answer
time: 105ms
memory: 91400kb
input:
1
output:
0
result:
wrong answer 1st numbers differ - expected: '1', found: '0'