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 O = 1000000007;
const int M = 200;
const int maxM = 207;
template <class T>
T rd() {
  bool f = 1;
  char c = getchar();
  for (; !isdigit(c); c = getchar())
    if (c == '-') f = 0;
  T x = 0;
  for (; isdigit(c); c = getchar()) x = x * 10 + c - 48;
  return f ? x : -x;
}
inline void Add(long long &x, long long y) {
  if ((x += y) >= O) x -= O;
}
inline void Mul(long long &x, long long y) { x = x * y % O; }
long long a[maxM];
long long iv[maxM], ifac[maxM], fac[maxM];
void init() {
  iv[1] = 1;
  for (int i = (2), _ = (M); i <= _; ++i) iv[i] = iv[O % i] * (O - O / i) % O;
  fac[0] = 1;
  for (int i = (1), _ = (M); i <= _; ++i) fac[i] = fac[i - 1] * i % O;
  ifac[0] = 1;
  for (int i = (1), _ = (M); i <= _; ++i) ifac[i] = ifac[i - 1] * iv[i] % O;
}
void pre(long long *a, int m) {
  a[0] = 1;
  for (int i = (0), _ = (m); i < _; ++i) {
    for (int j = (i), _ = (0); j >= _; --j) {
      Add(a[j + 1], a[j]);
      Mul(a[j], O - i);
    }
  }
  for (int i = (0), _ = (m); i <= _; ++i) Mul(a[i], ifac[m]);
}
inline long long C(int x, int y) {
  return 0 <= y && y <= x ? fac[x] * ifac[y] % O * ifac[x - y] % O : 0;
}
inline long long sgn(int x) { return x & 1 ? -1 : 1; }
namespace calc {
struct Rec {
  long long a, b;
  Rec(long long _a = 0, long long _b = 0) : a(_a), b(_b) {}
  inline Rec operator+(const Rec &t) const {
    return Rec((a + t.a) % O, (b + t.b) % O);
  }
  inline Rec operator-(const Rec &t) const {
    return Rec((a - t.a) % O, (b - t.b) % O);
  }
  inline Rec operator*(const Rec &t) const {
    return Rec((a * t.a + b * t.b * 5) % O, (a * t.b + b * t.a) % O);
  }
  inline Rec operator*(const long long d) const {
    return Rec(a * d % O, b * d % O);
  }
  inline void dec() {
    swap(a, b);
    Mul(b, iv[5]);
  }
  inline friend Rec pwd(Rec x, long long tms) {
    Rec res = Rec(1);
    for (; tms > 0; tms >>= 1, x = x * x)
      if (tms & 1) res = res * x;
    return res;
  }
};
Rec F(Rec x, long long tms) {
  ++tms;
  Rec res = 0, p = 1;
  int i = 0;
  while (tms >> i) ++i;
  for (--i; i >= 0; --i) {
    res = res + res * p;
    p = p * p;
    if (tms >> i & 1) {
      res = res + p;
      p = p * x;
    }
  }
  return res;
}
Rec S(long long L, long long R, int a, int b) {
  if (a == 0 && b == 0) return Rec(R - (L - 1));
  Rec t = pwd(Rec(iv[2], iv[2]), a) * pwd(Rec(iv[2], O - iv[2]), b);
  return F(t, R) - F(t, L - 1);
}
long long main(int i, long long L, long long R) {
  Rec res(0, 0);
  for (int j = (0), _ = (i); j <= _; ++j)
    res = res + S(L, R, j, i - j) * C(i, j) * sgn(i - j);
  while (i--) res.dec();
  assert(res.b == 0);
  return res.a;
}
}  // namespace calc
int main() {
  int m = rd<int>();
  long long l = rd<long long>() + 2, r = rd<long long>() + 2;
  init();
  pre(a, m);
  long long res = 0;
  for (int i = (0), _ = (m); i <= _; ++i) {
    long long tmp = calc::main(i, l, r);
    Mul(tmp, a[i]);
    Add(res, tmp);
  }
  printf("%I64d\n", (res % O + O) % O);
  return 0;
}