UOJ Logo

NOI.AC

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#207527#3741. 算算数Allen123456hello1001ms1192kbC++11396b2024-07-29 13:34:582024-07-29 17:00:57

answer

#include <bits/stdc++.h>
using namespace std;
/*
l[x,i]g(x,i)=xi
l[x,i]g(x,i)/i=x
l[x,i]/i=x/g(x,i)
*/
typedef long long LL;
LL solve(LL n){
    LL ans=1,cnt;
    for (LL i=2;i*i<=n;++i){
        cnt=1;while (!(n%i)){n/=i;++cnt;}ans*=cnt;
    }
    if (n!=1){ans<<=1;}
    return ans;
}
int main(){
    LL n;
    scanf("%lld",&n);
    printf("%lld",solve(n));
    return 0;
}

详细

小提示:点击横条可展开更详细的信息

Test #1:

score: 10
Accepted
time: 0ms
memory: 1188kb

input:

37

output:

2

result:

ok 1 number(s): "2"

Test #2:

score: 10
Accepted
time: 0ms
memory: 1188kb

input:

97

output:

2

result:

ok 1 number(s): "2"

Test #3:

score: 10
Accepted
time: 0ms
memory: 1192kb

input:

39

output:

4

result:

ok 1 number(s): "4"

Test #4:

score: 10
Accepted
time: 0ms
memory: 1192kb

input:

53

output:

2

result:

ok 1 number(s): "2"

Test #5:

score: 10
Accepted
time: 0ms
memory: 1192kb

input:

92884

output:

12

result:

ok 1 number(s): "12"

Test #6:

score: 10
Accepted
time: 0ms
memory: 1192kb

input:

95508

output:

36

result:

ok 1 number(s): "36"

Test #7:

score: 10
Accepted
time: 0ms
memory: 1192kb

input:

1516247450

output:

12

result:

ok 1 number(s): "12"

Test #8:

score: 10
Accepted
time: 0ms
memory: 1188kb

input:

5637113009

output:

8

result:

ok 1 number(s): "8"

Test #9:

score: 10
Accepted
time: 0ms
memory: 1188kb

input:

4442961915801

output:

12

result:

ok 1 number(s): "12"

Test #10:

score: 10
Accepted
time: 1ms
memory: 1192kb

input:

14937463156896

output:

72

result:

ok 1 number(s): "72"