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;
int k, l, r;
int M = 1000000000;
int p[26], lp;
int isp(int x) {
  for (int i = 2; i < x; i++)
    if (x % i == 0) return 0;
  return 1;
}
int c;
int _[3000000];
int __[3000000][10][2];
int Q[10][2];
void _add(int x) {
  c++;
  _[c] = x;
  for (int i = 0; i <= Q[0][0]; i++)
    __[c][i][0] = Q[i][0], __[c][i][1] = Q[i][1];
}
void dfs(int prod, int pp) {
  if (pp < 1) {
    _add(prod);
    return;
  }
  dfs(prod, pp - 1);
  Q[0][0]++;
  Q[Q[0][0]][0] = p[pp];
  Q[Q[0][0]][1] = 0;
  while (M / p[pp] >= prod) {
    Q[Q[0][0]][1]++;
    dfs(prod *= p[pp], pp - 1);
  }
  Q[0][0]--;
}
void prepare() {
  int i;
  lp = 0;
  for (i = 2; i <= k; i++)
    if (isp(i)) p[++lp] = i;
  dfs(1, lp);
}
int _max(int a, int b) { return a > b ? a : b; }
int _min(int a, int b) { return a < b ? a : b; }
void search(int Q[10][2], int a, int b, int n, int l, int G[100], int Max,
            int &ans) {
  int i, na = a, nb = b + 1, o;
  if (ans <= k) return;
  if (nb > Q[a][1]) na++, nb = 1;
  if (a > Q[0][0]) {
    if (Max + n < ans) ans = Max + n;
    return;
  }
  if (Max + n >= ans) return;
  if (b == 1) l = 1;
  for (i = l; i <= n + 1; i++) {
    if (G[i] == 0) G[i] = 1;
    o = G[i];
    G[i] *= Q[a][0];
    search(Q, na, nb, _max(n, i), i, G, _max(Max, G[i]), ans);
    if (ans <= k) return;
    G[i] = o;
  }
}
int Greedy(int Q[10][2], int bound) {
  int i, j, pro = 1, a = 1;
  for (i = 1; i <= Q[0][0]; i++)
    for (j = 1; j <= Q[i][1]; j++) {
      if (pro <= bound / Q[i][0])
        pro = pro * Q[i][0];
      else
        pro = Q[i][0], a++;
    }
  return a + bound;
}
int G[100];
int Get(int x, int Q[10][2]) {
  int a = _min(Greedy(Q, Q[1][0]), Greedy(Q, Q[1][0] * 2));
  for (int i = 1; G[i]; i++) G[i] = 0;
  search(Q, 1, 1, 0, 1, G, 1, a);
  return a;
}
set<int> ANS;
int main() {
  int ans = 0;
  scanf("%d %d %d", &l, &r, &k);
  prepare();
  for (int i = 1; i <= c; i++) {
    if (_[i] <= r && _[i] >= l) {
      if (_[i] == 137879618) _[i] = 137879618;
      if (Get(_[i], __[i]) <= k) ans++;
    }
  }
  printf("%d", ans);
  return 0;
}