QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#85320 | #5356. esperar | xiaoyaowudi | 0 | 2ms | 3540kb | C++14 | 406b | 2023-03-07 16:00:28 | 2023-03-07 16:01:27 |
Judging History
answer
#include <iostream>
#include <algorithm>
constexpr int N(110),p(998244353);
int main()
{
int a(1),b(1);
int n;std::cin>>n;
while(n--)
{
int t;std::cin>>t;
for(int i(2);i*i<=t;++i) if((t%i)==0)
{
int c(0);
while((t%i)==0) ++c,t/=i;
a=1ll*a*(c/2+1)%p;
b=1ll*b*((c+1)*(c+2)/2)%p;
}
if(t>1) b=3ll*b%p;
}
std::cout<<1ll*(a+b)*((p+1)/2)%p<<std::endl;
return 0;
}
详细
Subtask #1:
score: 0
Wrong Answer
Test #1:
score: 17
Accepted
time: 2ms
memory: 3336kb
input:
2 2 3
output:
5
result:
ok single line: '5'
Test #2:
score: -17
Wrong Answer
time: 2ms
memory: 3540kb
input:
4 5 8 8 9
output:
904
result:
wrong answer 1st lines differ - expected: '916', found: '904'
Subtask #2:
score: 0
Wrong Answer
Test #7:
score: 0
Wrong Answer
time: 0ms
memory: 3388kb
input:
100 78125 625 244140625 9765625 390625 9765625 244140625 3125 125 244140625 1 78125 25 48828125 25 3125 15625 9765625 25 125 9765625 1 625 125 244140625 3125 15625 48828125 9765625 1 125 390625 1953125 15625 1 5 9765625 5 48828125 125 9765625 25 5 48828125 390625 25 125 390625 9765625 9765625 625 31...
output:
517412673
result:
wrong answer 1st lines differ - expected: '476416688', found: '517412673'
Subtask #3:
score: 0
Wrong Answer
Test #12:
score: 0
Wrong Answer
time: 2ms
memory: 3416kb
input:
100 78125 625 244140625 9765625 390625 9765625 244140625 3125 125 244140625 1 78125 25 48828125 25 3125 15625 9765625 25 125 9765625 1 625 125 244140625 3125 15625 48828125 9765625 1 125 390625 1953125 15625 1 5 9765625 5 48828125 125 9765625 25 5 48828125 390625 25 125 390625 9765625 9765625 625 31...
output:
517412673
result:
wrong answer 1st lines differ - expected: '476416688', found: '517412673'