Problem: Maxim has got a calculator. The calculator has two integer cells. Initially, the first cell contains number 1, and the second cell contains number 0. In one move you can perform one of the following operations:

  1. Let's assume that at the current time the first cell contains number a, and the second cell contains number b. Write to the second cell number b + 1; 
  2. Let's assume that at the current time the first cell contains number a, and the second cell contains number b. Write to the first cell number a·b. 



Maxim is wondering, how many integers x (l ≤ x ≤ r) are there, such that we can write the number x to the first cell of the calculator, having performed at most p moves.

Input

The first line contains three integers: l, r, p (2 ≤ l ≤ r ≤ 109, 1 ≤ p ≤ 100). 

The numbers in the line are separated by single spaces.

Output

In a single line print a single integer — the answer to the problem.

Examples

Input

2 10 3


Output

1


Input

2 111 100


Output

106


Input

2 111 11


Output

47

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const int UNDEF = -1;
const long long INF = 1e18;
template <typename T>
inline bool chkmax(T &aa, T bb) {
  return aa < bb ? aa = bb, true : false;
}
template <typename T>
inline bool chkmin(T &aa, T bb) {
  return aa > bb ? aa = bb, true : false;
}
const int ms = 735425;
vector<int> vp = {2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47};
vector<int> vq = {53, 59, 61, 67, 71, 73, 79, 83, 89, 97};
const int LIM = 1000 * 1000 * 1000;
int f[ms];
const int mk = 100;
bool notok[mk];
char g[ms][mk];
const int LOGDIV = 5;
const int DIV = 1 << LOGDIV;
const int mh = (LIM / DIV) + 2;
int h[mh];
void gen() {
  for (auto &q : vq) notok[q] = true;
  f[0] = 1;
  int sz = 1;
  int nsz = sz;
  for (auto &p : vp) {
    for (int i = 0; i < sz; i++) {
      int x = f[i];
      while (1) {
        if (__builtin_smul_overflow(x, p, &x)) break;
        if (x > LIM) break;
        f[nsz] = x;
        ++nsz;
      }
    }
    sz = nsz;
  }
  sort(f, f + ms);
  for (int i = 0; i < ms; i++) {
    int x = f[i];
    h[(x >> LOGDIV) + 1] = i + 1;
  }
  int best = h[0];
  for (int i = 1; i < mh; i++) {
    if (h[i] > best)
      best = h[i];
    else
      h[i] = best;
  }
  memset(g, 127, sizeof g);
  memset(g[0], 0, sizeof g[0]);
  for (int xi = 0; xi < ms; xi++) {
    int x = f[xi];
    char has = 127;
    for (int k = 2; k < mk; k++) {
      if (g[xi][k] < has)
        has = g[xi][k];
      else
        g[xi][k] = has;
    }
    for (int y = x + x, k = 2; y <= LIM && k < mk; y += x, k++) {
      if (notok[k]) continue;
      char have = g[xi][k];
      if (have == 127) continue;
      int ydiv = y >> LOGDIV;
      int imin = h[ydiv], imax = h[ydiv + 1];
      while (imin < imax) {
        int imid = (imin + imax) >> 1;
        if (f[imid] < y)
          imin = imid + 1;
        else
          imax = imid;
      }
      chkmin(g[imin][k], (char)(have + (char)1));
    }
  }
}
const int mt = 1169;
long long vlarge[mt];
void gen2() {
  vlarge[0] = (((long long)1) << 32) | (1 << 16) | 0;
  int sz = 1;
  int nsz = sz;
  for (auto &p : vq) {
    for (int i = 0; i < sz; i++) {
      int x = vlarge[i] >> 32;
      int cnt = vlarge[i] & 0xffff;
      while (1) {
        if (__builtin_smul_overflow(x, p, &x)) break;
        if (x > LIM) break;
        ++cnt;
        vlarge[nsz] = (((long long)x) << 32) | (p << 16) | cnt;
        ++nsz;
      }
    }
    sz = nsz;
  }
  sort(vlarge, vlarge + mt);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  int l, r, allsteps;
  scanf("%d%d%d\n", &l, &r, &allsteps);
  gen();
  gen2();
  int ans = 0;
  for (int xi = 0; xi < ms; xi++) {
    int x = f[xi];
    for (int yi = 0; yi < mt; yi++) {
      long long got = vlarge[yi];
      int val = got >> 32;
      int y;
      if (__builtin_smul_overflow(x, val, &y)) break;
      if (y > r) break;
      if (y < l) continue;
      int lft = got & 0xffffffff;
      int p = lft >> 16;
      int cnt = lft & 0xffff;
      for (int k = p; k < mk; k++) {
        if (cnt + (int)g[xi][k] + k <= allsteps) {
          ans++;
          break;
        }
      }
    }
  }
  printf("%d\n", ans);
}