//#define _GLIBCXX_DEBUG
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#include <iostream>
#include <vector>
#include <set>
#include <map>
#include<algorithm>

#pragma GCC target("avx")
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")


using namespace std;

#define all(x) (x).begin(),(x).end()
typedef long long ll;
typedef unsigned int uint;
template<class T> inline bool chmax(T& a, const T& b) {if (a<b) {a=b; return true;} return false;}
template<class T> inline bool chmin(T& a, const T& b) {if (b<a) {a=b; return true;} return false;}
const int INF = 1000000000;

int main() {
  IOS;
  int K;
  cin >> K;
  ll ans = 0;
  set<tuple<int,int>>st;


  map<ll, int> mp;


  for (int i=1; i*i<=K; i++){
    for (int j=i; j*j<=K; j++){    
      if (i*j > K) continue;

        int kmax = K / i / j;
        chmax(mp[i*j], kmax); 
        vector<int>v = {i,j};
        sort(all(v));
        st.insert(make_tuple(v[0],v[1]));
        
      
    }
  }
  map<vector<int>, bool>isthere;
  for (tuple<int,int> tp: st){
    int first = get<0>(tp);
    int second = get<1>(tp);
    int kmax = mp[first*second];

    for (int i=max(first,second); i<=kmax; i++){
      int third2 = i;
      vector<int> v = {first,second,i};
      sort(all(v));

      //if (isthere[v]) continue;
      if (first == second and second == third2 and first == third2) ans++;

      else if (first == second or second==third2 or first==third2 ){
        ans += 3;
      }
      else {
        ans += 6;
      }

      //isthere[v] = true;
    }
  }
    

  cout << ans << endl;
  return 0;
}
#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0; i<(n); i++)
int k, t;
long long ans;
int main(){
	scanf("%d", &k);
	for(int i=1; i<=k; i++) for(int j=1; j*i<=k; j++) ans += k/i/j;
	printf("%lld\n", ans);
}