Problem: The Prodiggers are quite a cool band and for this reason, they have been the surprise guest at the ENTER festival for the past 80 years. At the beginning of their careers, they weren’t so successful, so they had to spend time digging channels to earn money; hence the name. Anyway, they like to tour a lot and have surprising amounts of energy to do extremely long tours. However, they hate spending two consecutive days without having a concert, so they would like to avoid it.

A tour is defined by a sequence of concerts and days-off. You need to count in how many ways The Prodiggers can select k different tours of the same length between l and r.

For example if k = 2, l = 1 and r = 2, if we define concert day as {1} and day-off as {0}, here are all possible tours: {0}, {1}, {00}, {01}, {10}, {11}. But tour 00 can not be selected because it has 2 days-off in a row. Now, we need to count in how many ways we can select k = 2 tours of the same length in range [1;2]. Here they are: {0,1}; {01,10}; {01,11}; {10,11}.

Since their schedule is quite busy, they want you to tell them in how many ways can do that, modulo 1 000 000 007 (109 + 7).

Input

The first line of the input contains three integers k, l and r (1 ≤ k ≤ 200, 1 ≤ l ≤ r ≤ 1018).

Output

Output a single number: the number of ways to select k different tours of the same length, modulo 1 000 000 007.

Example

Input

1 1 2


Output

5

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
long long int bigMOD(long long int n, long long int r) {
  if (r == 0) return 1LL;
  long long int ret = bigMOD(n, r / 2);
  ret = (ret * ret) % 1000000007;
  if (r % 2 == 1) ret = (ret * n) % 1000000007;
  return ret;
}
long long int inverse(long long int x) {
  return bigMOD(x % 1000000007, 1000000007 - 2);
}
long long int cMOD(long long int x) {
  x %= 1000000007;
  return (x >= 0) ? x : x + 1000000007;
}
struct cong {
  long long int a, b;
  cong(long long int x, long long int y) {
    a = cMOD(x);
    b = cMOD(y);
  }
  cong operator+(const cong &x) const { return cong(a + x.a, b + x.b); }
  cong operator-(const cong &x) const { return cong(a - x.a, b - x.b); }
  cong operator*(const cong &x) const {
    long long int c = x.a;
    long long int d = x.b;
    return cong((a * c) + (5 * b * d), (a * d) + (b * c));
  }
  cong operator/(long long int x) const {
    return cong(a * inverse(x), b * inverse(x));
  }
  cong operator/(const cong g) const {
    long long int c = g.a;
    long long int d = g.b;
    long long int x = cMOD(a * c - 5 * b * d) * inverse(c * c - 5 * d * d);
    long long int y = cMOD(a * d - b * c) * inverse(5 * d * d - c * c);
    return cong(x, y);
  }
};
cong bigMOD(cong n, long long int r) {
  if (r == 0) return cong(1, 0);
  cong ret = bigMOD(n, r / 2);
  ret = ret * ret;
  if (r % 2 == 1) ret = ret * n;
  return ret;
}
cong geosum(cong x, long long int n) {
  if (x.a == 1 && x.b == 0) return cong(n + 1, 0);
  return (bigMOD(x, n + 1) - cong(1, 0)) / (x - cong(1, 0));
}
cong alpha = cong(1, 1) / 2;
cong beta = cong(1, -1) / 2;
long long int c[205][205];
long long int a[205][205];
long long int fibPower(long long int n, int m) {
  cong ans = cong(0, 0);
  for (int j = 0; j <= m; j++) {
    cong t = bigMOD(alpha, j) * bigMOD(beta, m - j);
    cong x = cong(c[m][j], 0) * geosum(t, n);
    if ((m - j) & 1)
      ans = ans - x;
    else
      ans = ans + x;
  }
  ans = ans * bigMOD((cong(0, 1) / 5), m);
  return ans.a;
}
void PreCalc() {
  for (int i = 0; i < 205; i++) {
    c[i][0] = 1;
    for (int j = 1; j <= i; j++) {
      c[i][j] = c[i - 1][j] + c[i - 1][j - 1];
      c[i][j] %= 1000000007;
    }
  }
  a[0][0] = 1;
  for (int i = 1; i < 205; i++) {
    a[i][0] = 1;
    for (int j = 1; j <= i + 1; j++) {
      a[i][j] = a[i - 1][j] + i * a[i - 1][j - 1];
      a[i][j] %= 1000000007;
    }
  }
}
long long int query(long long int n, int k) {
  if (n < 0) return 0;
  long long int ans = 0;
  for (int i = 0; i <= k; i++) {
    long long int x = a[k - 1][i] * (fibPower(n + 2, k - i) - 1);
    if (i & 1)
      ans = cMOD(ans - x);
    else
      ans = cMOD(ans + x);
  }
  for (int i = 1; i <= k; i++) {
    ans *= inverse(i);
    ans %= 1000000007;
  }
  return ans;
}
int main() {
  PreCalc();
  long long int k, l, r;
  scanf("%lld %lld %lld", &k, &l, &r);
  long long int ans = query(r, k) - query(l - 1, k);
  cout << cMOD(ans) << endl;
}