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 MOD = 1e9 + 7, INV2 = (MOD + 1) >> 1;
long long K, L, R, A[407], C[407][407];
template <class T>
T poww(T a, long long b) {
  T times = 1;
  while (b) {
    if (b & 1) times = times * a % MOD;
    a = a * a % MOD;
    b >>= 1;
  }
  return times;
}
struct PII {
  long long st, nd;
  PII(long long _st = 0, long long _nd = 0) : st(_st), nd(_nd) {}
  PII operator=(long long b) { return *this = PII(b, 0); }
  bool operator!=(PII a) { return st != a.st || nd != a.nd; }
};
PII operator+(PII a, PII b) {
  return PII((a.st + b.st) % MOD, (a.nd + b.nd) % MOD);
}
PII operator-(PII a, PII b) {
  return PII((a.st + MOD - b.st) % MOD, (a.nd + MOD - b.nd) % MOD);
}
PII operator*(PII a, PII b) {
  return PII((a.st * b.st + 5 * a.nd * b.nd) % MOD,
             (a.st * b.nd + a.nd * b.st) % MOD);
}
PII operator*(PII a, long long b) {
  return PII(a.st * b % MOD, a.nd * b % MOD);
}
PII operator%(PII a, long long b) { return a; }
PII operator/(PII a, PII b) {
  return a * PII(b.st, MOD - b.nd) *
         poww((b.st * b.st - 5 * b.nd * b.nd % MOD + MOD) % MOD, MOD - 2);
}
void init() {
  A[1] = 1;
  long long times = 1;
  for (long long i = 1; i < K; ++i) {
    times = times * (i + 1) % MOD;
    for (long long j = i + 1; j; --j)
      A[j] = (A[j] * (MOD - i) + A[j - 1]) % MOD;
  }
  times = poww(times, MOD - 2);
  for (long long i = 1; i <= K; ++i) A[i] = A[i] * times % MOD;
  for (long long i = 0; i <= K; ++i) {
    C[i][0] = 1;
    for (long long j = 1; j <= i; ++j)
      C[i][j] = (C[i - 1][j] + C[i - 1][j - 1]) % MOD;
  }
}
long long solve(long long x, long long k) {
  PII all(0, 0);
  for (long long j = 0; j <= k; ++j) {
    PII cur = poww(PII(INV2, INV2), j) * poww(PII(INV2, MOD - INV2), k - j);
    if (cur != PII(1, 0))
      all = all + (poww(cur, x + 1) - PII(1, 0)) / (cur - PII(1, 0)) *
                      poww(MOD - 1, k - j) * C[k][j];
    else
      all = all + PII((x + 1) % MOD, 0) * poww(MOD - 1, k - j) * C[k][j];
  }
  all = all * poww(PII(0, poww(5ll, MOD - 2)), k);
  return all.st;
}
signed main() {
  cin >> K >> L >> R;
  init();
  L += 2;
  R += 2;
  long long ans = 0;
  for (long long i = 1; i <= K; ++i)
    ans = (ans + (solve(R, i) - solve(L - 1, i) + MOD) * A[i]) % MOD;
  cout << ans;
  return 0;
}