#include <bits/stdc++.h>
using namespace std;
const int64_t mn = int64_t(1e5) + 10;
const int64_t mod = int64_t(1e9) + 7;
int64_t n, k;
struct mat {
  vector<vector<long long> > a;
  mat(){};
  mat(int64_t x, int64_t y) { a.resize(x, vector<long long>(y, 0)); }
  mat operator*(const mat& b) {
    mat c(a.size(), b.a.size());
    for (int64_t i = 0; i < c.a.size(); ++i)
      for (int64_t j = 0; j < c.a[0].size(); ++j)
        for (int64_t k = 0; k < b.a.size(); ++k) {
          c.a[i][j] += a[i][k] * b.a[k][j];
          c.a[i][j] %= mod;
        }
    return c;
  }
};
mat a(101, 1), b(101, 101);
void docfile() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  if (ifstream("test"
               ".inp")) {
    freopen(
        "test"
        ".inp",
        "r", stdin);
    freopen(
        "test"
        ".out",
        "w", stdout);
  } else if (ifstream("DREAM"
                      ".inp")) {
    freopen(
        "DREAM"
        ".inp",
        "r", stdin);
    freopen(
        "DREAM"
        ".out",
        "w", stdout);
  }
}
void enter() {
  cin >> n >> k;
  int64_t x;
  for (int64_t i = 0; i < n; ++i) {
    cin >> x;
    ++b.a[0][x - 1];
  }
}
void init() {}
mat po(mat a, int64_t n) {
  if (n == 1) return a;
  mat te = po(a, n >> 1);
  te = te * te;
  return n & 1 ? te * a : te;
}
void solve() {
  if (k == 0) {
    cout << 1;
    exit(0);
  }
  a.a[0][0] = a.a[100][0] = b.a[100][100] = b.a[0][100] = 1;
  for (int64_t i = 1; i < 100; ++i) b.a[i][i - 1] = 1;
  b = po(b, k);
  a = b * a;
}
void print_result() { cout << a.a[0][0]; }
int32_t main() {
  docfile();
  int64_t t = 1;
  for (int64_t tt = 0; tt < t; ++tt) {
    enter();
    init();
    solve();
    print_result();
  }
}
