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;
inline long long read() {
  long long s = 0, t = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') t = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9')
    s = (s << 3) + (s << 1) + (ch ^ 48), ch = getchar();
  return s * t;
}
const int P = 1e9 + 7;
const int N = 65536;
namespace MTT {
const long double Pi = acos(-1);
const int M = 32767;
int L, p[N];
struct cp {
  long double r, i;
  cp(const long double &r = 0, const long double &i = 0) : r(r), i(i) {}
  cp operator+(const cp &B) { return cp(r + B.r, i + B.i); }
  cp operator-(const cp &B) { return cp(r - B.r, i - B.i); }
  cp operator*(const cp &B) { return cp(r * B.r - i * B.i, r * B.i + i * B.r); }
  cp operator/(const long double &B) { return cp(r / B, i / B); }
} w[N], A[N], B[N], C[N], D[N];
int Mod(int x) { return x >= P ? x - P : x; }
void Init(int n) {
  for (L = 0; (1 << L) <= n; L++)
    ;
  for (int i = 0; i < (1 << L); i++)
    p[i] = (p[i >> 1] >> 1) | ((i & 1) << L - 1);
  L = (1 << L);
}
void FFT(cp *A, int n, int tp) {
  for (int i = 0; i < n; i++)
    if (i < p[i]) swap(A[i], A[p[i]]);
  for (int m = 1; m < n; m <<= 1) {
    cp t0 = cp(cos(Pi / m), tp * sin(Pi / m));
    w[0] = cp(1, 0);
    for (int i = 1; i < m; i++) w[i] = w[i - 1] * t0;
    for (int k = 0; k < n; k += (m << 1))
      for (int i = k; i < k + m; i++) {
        cp x = A[i], y = A[i + m] * w[i - k];
        A[i] = x + y, A[i + m] = x - y;
      }
  }
  if (tp ^ 1)
    for (int i = 0; i < n; i++) A[i] = A[i] / n;
}
vector<int> operator*(vector<int> f, vector<int> g) {
  int n = f.size() - 1, m = g.size() - 1;
  Init(n + m), f.resize(L), g.resize(L);
  for (int i = 0; i < L; i++) A[i] = cp(f[i] >> 15, f[i] & M);
  for (int i = 0; i < L; i++) B[i] = cp(g[i] >> 15, g[i] & M);
  FFT(A, L, 1), FFT(B, L, 1);
  for (int i = 0; i < L; i++) {
    cp x = A[i], y = A[(L - i) & (L - 1)];
    C[i] = cp((x.r + y.r) / 2, (x.i - y.i) / 2) * B[i];
    D[i] = cp((x.i + y.i) / 2, (y.r - x.r) / 2) * B[i];
  }
  FFT(C, L, -1), FFT(D, L, -1);
  for (int i = 0; i <= n + m; i++) {
    f[i] = ((llround(C[i].r) % P << 30) % P +
            ((llround(C[i].i) + llround(D[i].r)) % P << 15) % P +
            llround(D[i].i) % P) %
           P;
  }
  return f.resize(n + m + 1), f;
}
}  // namespace MTT
using namespace MTT;
vector<int> f, g;
long long n, m, Ans;
int fac[N], inv[N], coe[N];
int ksm(int x, int k) {
  int res = 1;
  while (k) {
    if (k & 1) res = 1ll * res * x % P;
    x = 1ll * x * x % P, k >>= 1;
  }
  return res;
}
void Pre(int n) {
  coe[0] = 1;
  for (int i = 1; i <= n; i++) coe[i] = 2ll * coe[i - 1] % P;
  fac[0] = 1;
  for (int i = 1; i <= n; i++) fac[i] = 1ll * fac[i - 1] * i % P;
  inv[n] = ksm(fac[n], P - 2);
  for (int i = n; i >= 1; i--) inv[i - 1] = 1ll * inv[i] * i % P;
}
int Calc(int n, int m) { return 1ll * fac[n] * inv[m] % P * inv[n - m] % P; }
void Solve(int n) {
  if (n == 1) {
    f.resize(m + 1), f[0] = 0;
    for (int i = 1; i <= m; i++) f[i] = inv[i];
    return;
  }
  int len = n >> 1, flag = 0;
  if (n & 1) n--, flag = 1;
  Solve(len);
  g.resize(m + 1), g[0] = f[0];
  for (int i = 1, t = 1; i <= m; i++) {
    t = 1ll * t * coe[len] % P;
    g[i] = 1ll * t * f[i] % P;
  }
  f = f * g, f.resize(m + 1);
  if (flag) {
    g.resize(m + 1), g[0] = 0;
    for (int i = 1, t = 1; i <= m; i++) {
      t = 1ll * t * coe[n] % P;
      g[i] = 1ll * t * inv[i] % P;
    }
    f = f * g, f.resize(m + 1);
  }
}
int main() {
  n = read(), m = read();
  if (n > m) return printf("0"), 0;
  Pre(m), Solve(n);
  for (int i = 1; i <= m; i++)
    Ans = Mod(Ans + 1ll * f[i] * fac[i] % P * Calc(m, i) % P);
  printf("%lld", Ans);
  return 0;
}