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;
const long long Mo = 1000000007LL;
struct Num {
  long long a, b;
  Num(long long a = 0, long long b = 0) : a(a), b(b) {}
};
const Num temp = Num(1, 0);
Num operator+(Num a, Num b) { return Num((a.a + b.a) % Mo, (a.b + b.b) % Mo); }
Num operator-(Num a, Num b) {
  return Num((a.a - b.a + Mo) % Mo, (a.b - b.b + Mo) % Mo);
}
Num operator*(Num a, Num b) {
  return Num((a.a * b.a + 5LL * a.b * b.b) % Mo, (a.b * b.a + b.b * a.a) % Mo);
}
long long co[210], C[210][210], L, R, ans;
int K;
long long fpm(long long a, long long b) {
  long long ans = 1LL;
  if (!a) return 0LL;
  for (; b; b >>= 1) {
    if (b & 1LL) ans *= a, ans %= Mo;
    a *= a, a %= Mo;
  }
  return ans;
}
Num Fpm(Num u, long long n) {
  Num ans = temp;
  for (; n; n >>= 1) {
    if (n & 1LL) ans = ans * u;
    u = u * u;
  }
  return ans;
}
Num cnt_sum(Num u, long long n, Num &x) {
  if (n == 1LL) {
    x = u;
    return u;
  }
  Num S = cnt_sum(u, n >> 1, x);
  S = S * (temp + x);
  x = x * x;
  if (n & 1LL) {
    x = x * u;
    S = S + x;
  }
  return S;
}
long long count(long long n, int m) {
  if (!m) return n % Mo;
  Num ans = Num(0, 0);
  long long Inv2 = fpm(2, Mo - 2LL);
  Num sqr5 = Num(0, fpm(5LL, Mo - 2LL));
  sqr5 = Fpm(sqr5, m);
  for (int i = 0; i <= m; i++) {
    Num sing = Num(C[m][i], 0);
    if (i & 1) sing.a *= -1LL;
    Num A = Num(Inv2, fpm(Mo - 2LL, Mo - 2LL) % Mo), B = Num(Inv2, Inv2);
    A = Fpm(A, i);
    B = Fpm(B, m - i);
    A = A * B;
    Num js;
    Num S = cnt_sum(A, n, js);
    ans = ans + S * sing;
  }
  ans = ans * sqr5;
  return ans.a;
}
int main() {
  cin >> K >> L >> R;
  co[0] = 1LL;
  C[0][0] = 1LL;
  for (int i = 1; i <= K; i++) {
    C[i][0] = 1LL;
    for (int j = 1; j <= i; j++) C[i][j] = (C[i - 1][j] + C[i - 1][j - 1]) % Mo;
  }
  for (int k = 1; k <= K; k++) {
    for (int i = k; i >= 1; i--)
      co[i] = (co[i] * ((1 - k + Mo) % Mo) + co[i - 1]) % Mo;
    co[0] = co[0] * (1 - k + Mo) % Mo;
  }
  for (int k = 0; k <= K; k++) {
    long long sing = (count(R + 2, k) - count(L + 1, k) + Mo) % Mo;
    (ans += co[k] * sing) %= Mo;
  }
  for (int k = 1; k <= K; k++) ans *= fpm(k, Mo - 2LL), ans %= Mo;
  cout << (ans + Mo) % Mo << endl;
  return 0;
}