| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 57031 | 杨竣周 | 迟到的生日 | C++ | Time Limit Exceeded | 50 | 1000 MS | 264 KB | 395 | 2022-08-03 17:41:20 |
#include<bits/stdc++.h> using namespace std; int _(int x){ unordered_map<int,int> primes; for(int i=2;i<=x/i;i++){ while(x%i==0){ x/=i; primes[i]++; } } if(x>1) primes[x]++; long long res=1; for(auto prime:primes){ res=res*(1+prime.second); } return res; } int a,b,ans; int main(){ cin>>a>>b; for(int i=a;i<=b;i++) ans+=_(i); cout<<ans; return 0; }