题目大意:
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
const ll mod=1e9+7;
ll n;
ll lcm(ll x,ll y){
return x/__gcd(x,y)*y;
}
int main(){
int T;
cin >> T;
while(T--){
cin >> n;
ll ans=n%mod;
for(ll i=1,j=1;n/j;i++,j=lcm(j,i)){
ans=(ans+n/j)%mod;
}
cout << ans << endl;
}
return 0;
}
标签:Function,CF1542C,int,ll,Strange,ans,mod
From: https://www.cnblogs.com/ningziang/p/17670551.html