#include <bits/stdc++.h>
using namespace std;
const int MAX_N = 101;
const int mod = 1e9 + 7;
const int N = 100;
void madd(int& a, int b) {
  a += b;
  if (a >= mod) a -= mod;
}
int mul(int a, int b) { return ((long long)a * b) % mod; }
int mpow(int a, int n) {
  int r = 1;
  while (n > 0) {
    if (n & 1) r = mul(r, a);
    a = mul(a, a);
    n >>= 1;
  }
  return r;
}
int n, x;
int f[MAX_N][MAX_N];
int m[MAX_N][MAX_N];
int dp[MAX_N];
int tmp[MAX_N][MAX_N];
void mmul(int A[MAX_N][MAX_N], int B[MAX_N][MAX_N]) {
  for (int i = 0; i < MAX_N; i++)
    for (int j = 0; j < MAX_N; j++) {
      tmp[i][j] = 0;
      for (int k = 0; k < MAX_N; k++) madd(tmp[i][j], mul(A[i][k], B[k][j]));
    }
  for (int i = 0; i < MAX_N; i++)
    for (int j = 0; j < MAX_N; j++) A[i][j] = tmp[i][j];
}
int main() {
  scanf("%d%d", &n, &x);
  for (int i = 0; i < n; i++) {
    int d;
    scanf("%d", &d);
    f[0][d - 1]++;
  }
  f[0][N] = 1;
  f[N][N] = 1;
  for (int i = 1; i < N; i++) f[i][i - 1] = 1;
  dp[0] = 1;
  for (int j = 1; j <= N - 1; j++) {
    dp[j] = 1;
    for (int k = 1; k <= j; k++) {
      madd(dp[j], mul(f[0][k - 1], dp[j - k]));
    }
  }
  dp[N] = 1;
  if (x <= N - 1) {
    printf("%d\n", dp[x]);
  } else {
    for (int i = 0; i <= N; i++) m[i][i] = 1;
    int t = x - (N - 1);
    for (; t > 0; t >>= 1, mmul(f, f))
      if (t & 1) mmul(m, f);
    int r = 0;
    for (int j = 0; j <= N - 1; j++) madd(r, mul(m[0][j], dp[N - 1 - j]));
    madd(r, m[0][N]);
    printf("%d\n", r);
  }
  return 0;
}
