#include #define ll long long #define REP(i, n) for(int i=0;i> N >> M; ll res = 0; ll j; ll NN = 0; for(int i=0;i*i<=M;i++){ NN = i+1; } for(j = 1; j*j <= M; j++) { ll low = (N-1)/j; ll high = M/j; ll NNN = max(j*NN, N); ll low2 = (NNN-1)/j; res += (high - low); if (NNN <= M) res += (high - low2); } cout << res << endl; }