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;
inline char getch() {
  static char buf[10000], *p1 = buf, *p2 = buf;
  return p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 10000, stdin), p1 == p2)
             ? EOF
             : *p1++;
}
inline long long read() {
  long long s = 0, f = 1;
  char ch = getch();
  while ((ch < '0' || ch > '9') && ch != EOF)
    f = (ch == '-' ? -1 : 1), ch = getch();
  while (ch >= '0' && ch <= '9') s = s * 10 + ch - '0', ch = getch();
  return s * f;
}
void File() {
  freopen(
      "filename"
      ".in",
      "r", stdin);
  freopen(
      "filename"
      ".out",
      "w", stdout);
}
namespace ____ {
const int Mod = 1e9 + 7;
long long ksm(long long, long long, long long);
struct Num {
  long long x, y;
  Num(long long x = 0, long long y = 0) : x(x % Mod), y(y % Mod) {}
  void print() { cout << "(" << x << "," << y << ")\n"; }
};
int ba;
long long M(long long x) { return x >= Mod ? x - Mod : x; }
Num operator+(const Num &A, const Num &B) {
  return Num(M(A.x + B.x), M(A.y + B.y));
}
Num operator-(const Num &A, const Num &B) {
  return Num(M(A.x - B.x + Mod), M(A.y - B.y + Mod));
}
Num operator*(const Num &A, const Num &B) {
  return Num(M(A.x * B.x % Mod + A.y * B.y % Mod * ba % Mod),
             M(A.x * B.y % Mod + A.y * B.x % Mod));
}
Num operator/(const Num &A, const Num &B) {
  long long inv =
      ksm(B.x * B.x % Mod - B.y * B.y % Mod * ba % Mod + Mod, Mod - 2, Mod);
  return Num(M(A.x * B.x % Mod - A.y * B.y % Mod * ba % Mod + Mod) * inv % Mod,
             M(A.y * B.x % Mod - A.x * B.y % Mod + Mod) * inv % Mod);
}
long long S1[1010][1010], inv[1010], finv[1010];
long long C[1010][1010];
Num Alpha, A, Beta, B;
int m;
long long ksm(long long x, long long y, long long p) {
  x %= p;
  long long res = 1;
  for (; y; y >>= 1, x = x * x % p)
    if (y & 1) res = res * x % p;
  return res;
}
Num ksm(Num x, long long y) {
  Num res(1, 0);
  for (; y; y >>= 1, x = x * x)
    if (y & 1) res = res * x;
  return res;
}
void deal() {
  ba = 5;
  long long i5 = inv[5], i2 = inv[2];
  A = Num(0, 1) * Num(i5, 0);
  B = Num(0, Mod - 1) * Num(i5, 0);
  Alpha = Num(1, 1) * Num(i2, 0);
  Beta = Num(1, Mod - 1) * Num(i2, 0);
}
void calc() {
  Num Ans(0, 0);
  long long l, r, k;
  k = read(), l = read() + 2, r = read() + 2;
  for (int i = 0; i <= k; i++) {
    long long coe = S1[k][i] * (((k - i) & 1) ? Mod - 1 : 1) % Mod;
    for (int j = 0; j <= i; j++) {
      Num tmp = ksm(A, j) * ksm(B, i - j) * Num(coe * C[i][j] % Mod, 0);
      Num q = ksm(Alpha, j) * ksm(Beta, i - j);
      if (q.x == 1 && q.y == 0)
        Ans = Ans + tmp * q * Num(r - l + 1, 0);
      else
        Ans = Ans + tmp * (ksm(q, r + 1) - ksm(q, l)) / (q - Num(1, 0));
    }
  }
  cout << Ans.x * finv[k] % Mod << "\n";
}
void Main() {
  S1[0][0] = C[0][0] = 1;
  for (int i = 1; i <= 1000; i++) {
    C[i][0] = 1;
    for (int j = 1; j <= i; j++)
      S1[i][j] = M(S1[i - 1][j - 1] + (i - 1) * S1[i - 1][j] % Mod),
      C[i][j] = M(C[i - 1][j] + C[i - 1][j - 1]);
  }
  inv[0] = inv[1] = finv[0] = finv[1] = 1;
  for (int i = 2; i <= 1000; i++) {
    inv[i] = Mod - Mod / i * inv[Mod % i] % Mod;
    finv[i] = finv[i - 1] * inv[i] % Mod;
  }
  deal();
  calc();
}
}  // namespace ____
int main() {
  ____::Main();
  return 0;
}