#include <bits/stdc++.h>
using namespace std;
const int M = 103;
const long long MOD = 1e9 + 7;
struct Matrix {
  int nn, mm;
  long long d[M][M];
  void init() {
    memset(d, 0, sizeof(d));
    for (int i = 0; i < M; ++i) d[i][i] = 1;
  }
  void clear() { memset(d, 0, sizeof(d)); }
  Matrix(int n, int m) : nn(n), mm(m) {}
  Matrix operator*(const Matrix& b) {
    Matrix c(nn, b.mm);
    for (int i = 0; i < nn; ++i)
      for (int j = 0; j < b.mm; ++j) {
        c.d[i][j] = 0;
        for (int k = 0; k < b.nn; ++k)
          c.d[i][j] = (c.d[i][j] + d[i][k] * b.d[k][j]) % MOD;
      }
    return c;
  }
};
Matrix expo(Matrix a, long long b) {
  Matrix ans(a.nn, a.mm);
  ans.init();
  for (; b; b >>= 1, a = a * a) {
    if (b & 1) {
      ans = ans * a;
      b ^= 1;
    }
  }
  return ans;
}
int n, x;
Matrix trans(101, 101), ans(101, 1);
void Init() {
  for (int i = 1; i < 100; ++i) {
    trans.d[i - 1][i] = 1;
  }
  trans.d[100][100] = 1;
  for (int i = 1; i <= 100; ++i) {
    ans.d[i - 1][0] = trans.d[100][100 - i];
    for (int j = 1; j <= 100; ++j)
      if (j < i) {
        ans.d[i - 1][0] =
            (ans.d[i - 1][0] + ans.d[i - j - 1][0] * trans.d[100][100 - j]) %
            MOD;
      } else
        break;
    ans.d[100][0] = (ans.d[100][0] + ans.d[i - 1][0]) % MOD;
  }
}
int main() {
  scanf("%d%d", &n, &x);
  trans.clear();
  while (n--) {
    int val;
    scanf("%d", &val);
    trans.d[99][100 - val]++;
    trans.d[100][100 - val]++;
  }
  Init();
  if (x <= 100) {
    long long res = 1;
    for (int i = 1; i <= x; ++i) res = (res + ans.d[i - 1][0]) % MOD;
    printf("%I64d", res);
    return 0;
  }
  ans = expo(trans, x - 100) * ans;
  printf("%I64d", (ans.d[100][0] + 1) % MOD);
  return 0;
}
