Problem: Let's define the transformation P of a sequence of integers a1, a2, ..., an as b1, b2, ..., bn, where bi = a1 | a2 | ... | ai for all i = 1, 2, ..., n, where | is the bitwise OR operation.

Vasya consequently applies the transformation P to all sequences of length n consisting of integers from 1 to 2k - 1 inclusive. He wants to know how many of these sequences have such property that their transformation is a strictly increasing sequence. Help him to calculate this number modulo 109 + 7.

Input

The only line of the input contains two integers n and k (1 ≤ n ≤ 1018, 1 ≤ k ≤ 30 000).

Output

Print a single integer — the answer to the problem modulo 109 + 7.

Examples

Input

1 2


Output

3


Input

2 3


Output

30


Input

3 3


Output

48

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int maxN = 1 << 18, M = 1 << 15, mod = 1e9 + 7;
const long double pi = acos(-1.0);
struct Complex {
  long double x, y;
  Complex(long double X = 0, long double Y = 0) {
    x = X;
    y = Y;
  }
};
Complex operator+(Complex a, Complex b) {
  return Complex(a.x + b.x, a.y + b.y);
}
Complex operator-(Complex a, Complex b) {
  return Complex(a.x - b.x, a.y - b.y);
}
Complex operator*(Complex a, Complex b) {
  return Complex(a.x * b.x - a.y * b.y, a.x * b.y + a.y * b.x);
}
Complex operator/(Complex a, long double p) {
  return Complex(a.x / p, a.y / p);
}
int m;
int lim, r[maxN + 1];
int fac[maxN + 1], inv[maxN + 1];
int stk[maxN + 1], top;
int ans[maxN + 1], na[maxN + 1];
long long n;
Complex A0[maxN + 1], A1[maxN + 1], B[maxN + 1];
Complex wn[maxN + 1];
inline int mpow(int a, int x) {
  int ans = 1;
  while (x) {
    if (x & 1) ans = 1ll * ans * a % mod;
    a = 1ll * a * a % mod;
    x >>= 1;
  }
  return ans;
}
inline void pre() {
  fac[0] = 1;
  for (int i = 1; i <= m; i++) fac[i] = 1ll * fac[i - 1] * i % mod;
  inv[m] = mpow(fac[m], mod - 2);
  for (int i = m - 1; i >= 0; i--) inv[i] = 1ll * inv[i + 1] * (i + 1) % mod;
  int cnt = 0;
  lim = 1;
  while (lim <= (m << 1)) lim <<= 1, cnt++;
  for (int i = 0; i < lim; i++) r[i] = (r[i >> 1] >> 1) | ((i & 1) << cnt - 1);
  for (int mid = 1; mid < lim; mid <<= 1) {
    Complex W(std::cos(pi / mid), std::sin(pi / mid));
    wn[mid] = Complex(1, 0);
    for (int j = 1; j < mid; j++) wn[mid + j] = wn[mid + j - 1] * W;
  }
}
inline void FFT(Complex *a, int type) {
  for (int i = 0; i < lim; i++)
    if (i < r[i]) swap(a[i], a[r[i]]);
  for (int mid = 1; mid < lim; mid <<= 1)
    for (int i = 0; i < lim; i += (mid << 1))
      for (int j = 0; j < mid; j++) {
        Complex x = a[i + j], y = a[i + mid + j] * wn[mid + j];
        a[i + j] = x + y;
        a[i + mid + j] = x - y;
      }
  if (type == -1) {
    for (int i = 0; i < lim; i++) a[i] = a[i] / lim;
    reverse(a + 1, a + lim);
  }
}
inline void Mul() {
  for (int i = 0; i <= m; i++) {
    A0[i].x = A1[i].x = ans[i] / M;
    A0[i].y = ans[i] % M;
    A1[i].y = -ans[i] % M;
    B[i].x = na[i] / M, B[i].y = na[i] % M;
  }
  FFT(A0, 1);
  FFT(A1, 1);
  FFT(B, 1);
  for (int i = 0; i < lim; i++) A0[i] = A0[i] * B[i], A1[i] = A1[i] * B[i];
  FFT(A0, -1);
  FFT(A1, -1);
  for (int i = 0; i <= m; i++) {
    long long res = 0;
    res += (long long)((A0[i].x + A1[i].x) / 2 + 0.5) % mod * M % mod * M % mod;
    res += (long long)(A0[i].y + 0.5) % mod * M % mod;
    res += (long long)((A1[i].x - A0[i].x) / 2 + 0.5) % mod;
    res = (res % mod + mod) % mod;
    ans[i] = res;
  }
  for (int i = 0; i < lim; i++) A0[i] = A1[i] = B[i] = Complex(0, 0);
}
inline void solve() {
  int tn = n - 1;
  while (tn) stk[++top] = tn, tn = (tn - 1) >> 1;
  for (int i = 1; i <= m; i++) ans[i] = inv[i];
  while (top) {
    int n = stk[top--];
    na[0] = 0;
    for (int i = 1, v = mpow(2, (n - 1) / 2 + 1), t = v; i <= m;
         i++, t = 1ll * t * v % mod)
      na[i] = 1ll * ans[i] * t % mod;
    Mul();
    if (!(n & 1)) {
      na[0] = 0;
      for (int i = 1, v = mpow(2, n), t = v; i <= m; i++, t = 1ll * t * v % mod)
        na[i] = 1ll * t * inv[i] % mod;
      Mul();
    }
  }
}
int main() {
  scanf("%lld %d", &n, &m);
  if (n > m) return puts("0"), 0;
  pre();
  solve();
  int res = 0;
  for (int i = n; i <= m; i++)
    res = (res + 1ll * inv[m - i] * ans[i] % mod) % mod;
  res = 1ll * res * fac[m] % mod;
  printf("%d\n", res);
  return 0;
}