#include <bits/stdc++.h>
using namespace std;
const int N = 100100;
const long long B = 1000000007;
int x, n, t;
struct Matrix {
  long long mx[102][102];
} a, c;
Matrix mul(Matrix a, Matrix b) {
  Matrix c;
  for (int i = 1; i <= 101; i++)
    for (int j = 1; j <= 101; j++) {
      c.mx[i][j] = 0;
      for (int k = 1; k <= 101; k++)
        c.mx[i][j] = (c.mx[i][j] + a.mx[i][k] * b.mx[k][j]) % B;
    }
  return c;
}
Matrix pw(int k) {
  if (k == 1) return a;
  Matrix b = pw(k / 2);
  if (k % 2 == 0)
    return mul(b, b);
  else
    return mul(mul(b, b), a);
}
int main() {
  cin >> n >> x;
  memset(a.mx, 0, sizeof(a.mx));
  if (x == 0) {
    cout << 1;
    return 0;
  }
  for (int i = 0; i < n; i++) {
    cin >> t;
    a.mx[1][t]++;
  }
  a.mx[1][101] = 1ll;
  a.mx[101][101] = 1;
  ;
  ;
  for (int i = 2; i <= 100; i++) a.mx[i][i - 1] = 1;
  c = pw(x);
  cout << (c.mx[1][1] + c.mx[1][101]) % B;
  return 0;
}
