Accepted
代码
#include <stdio.h>
#include <iostream>
using namespace std;
typedef long long ll;
int main(){
ll a;
cin>>a;
ll ans = 0;ll temp = 0;ll t;
for(ll i = 1;i*i*i<=a;i++,ans++){
t = a/i;
for(ll j= i+1;j*j<=t;j++)
temp+=a/(i*j)-j;
}
ans+=temp*6;
temp = 0;
for(ll i = 1;i*i<=a;i++){
t = i*i;
temp+=a/t;
if(t*i<=a) temp--;
}
ans+=temp*3;
cout<<ans;
return 0;
}