#include using namespace std; typedef long long ll; int main() { ll ans=0; int n; cin>>n; for(int i=0;i>x; for(ll j=2;j*j<=x;j++) { while(x%j==0) { ans+=x; x/=j; } } if(x>1) ans+=x; } cout<