Submission #2201057
Source Code Expand
#include<cstdio> #include<cstring> using namespace std; static const long long int INF=1e9+7; int main() { int n; int a[10004]; while(scanf("%d",&n)!=EOF) { memset(a,0,sizeof(a)); for(int i=2;i<=n;i++) { int m=i; for(int j=2;j<=m;j++) { while(m%j==0) { a[j]++; m/=j; } } if(m!=1) a[m]++; } long long int ans=1; for(int i=1;i<=n;i++) { if(a[i]!=0) ans=(ans*(a[i]+1))%INF; } printf("%lld\n",ans); } return 0; }
Submission Info
Submission Time | |
---|---|
Task | C - Factors of Factorial |
User | vjudge2 |
Language | Bash (GNU bash v4.3.11) |
Score | 0 |
Code Size | 487 Byte |
Status | RE |
Exec Time | 6 ms |
Memory | 504 KB |
Judge Result
Set Name | Sample | All | ||||
---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 0 / 300 | ||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | sample_01.txt, sample_02.txt, sample_03.txt |
All | sample_01.txt, sample_02.txt, sample_03.txt, subtask_1_certain_01.txt, subtask_1_certain_02.txt, subtask_1_certain_03.txt, subtask_1_certain_04.txt, subtask_1_rand_01.txt, subtask_1_rand_02.txt, subtask_1_rand_03.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
sample_01.txt | RE | 6 ms | 504 KB |
sample_02.txt | RE | 3 ms | 504 KB |
sample_03.txt | RE | 3 ms | 504 KB |
subtask_1_certain_01.txt | RE | 2 ms | 504 KB |
subtask_1_certain_02.txt | RE | 2 ms | 504 KB |
subtask_1_certain_03.txt | RE | 2 ms | 504 KB |
subtask_1_certain_04.txt | RE | 2 ms | 504 KB |
subtask_1_rand_01.txt | RE | 2 ms | 504 KB |
subtask_1_rand_02.txt | RE | 2 ms | 504 KB |
subtask_1_rand_03.txt | RE | 3 ms | 504 KB |