Problem: After playing with her beautiful array, Mishka decided to learn some math. After learning how to multiply, divide and what is divisibility, she is now interested in solving the following problem.

You are given integer k and array a1, a2, ..., an of n integers. You are to find non-empty subsequence of array elements such that the product of its elements is divisible by k and it contains minimum possible number of elements.

Formally, you are to find a sequence of indices 1 ≤ i1 < i2 < ... < im ≤ n such that <image> is divisible by k while m is minimum possible among all such variants.

If there are more than one such subsequences, you should choose one among them, such that sum of its elements is minimum possible.

Mishka quickly solved this problem. Will you do so?

Input

The first line of the input contains two integers n and k (1 ≤ n ≤ 1 000, 1 ≤ k ≤ 1012).

The second line of the input contains n integers a1, a2, ..., an (1 ≤ ai ≤ 1012) — array elements.

Output

Print single positive integer m in the first line — the number of elements in desired sequence.

In the second line print m distinct integers — the sequence of indices of given array elements, which should be taken into the desired sequence. 

If there are more than one such subsequence (e.g. subsequence of minimum possible number of elements and with minimum possible sum of elements), you can print any of them.

If there are no such subsequences, print  - 1 in the only line.

Example

Input

5 60
2 4 6 5 2


Output

3
4 3 1 

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using std::abs;
using std::bitset;
using std::cerr;
using std::cin;
using std::copy;
using std::cout;
using std::deque;
using std::endl;
using std::fill;
using std::fixed;
using std::greater;
using std::iota;
using std::istream;
using std::lower_bound;
using std::make_pair;
using std::make_tuple;
using std::map;
using std::max;
using std::max_element;
using std::min;
using std::min_element;
using std::multiset;
using std::next_permutation;
using std::nth_element;
using std::ostream;
using std::pair;
using std::priority_queue;
using std::queue;
using std::reverse;
using std::rotate;
using std::set;
using std::sort;
using std::string;
using std::swap;
using std::tie;
using std::tuple;
using std::unique;
using std::unordered_map;
using std::unordered_set;
using std::upper_bound;
using std::vector;
long long rnd(long long x, long long y) {
  static auto gen = std::bind(std::uniform_int_distribution<long long>(),
                              std::mt19937(960172));
  return gen() % (y - x + 1) + x;
}
long long gcd(long long a, long long b) {
  while (b > 0) {
    long long t = a % b;
    a = b;
    b = t;
  }
  return a;
}
template <typename T>
T sqr(T const& a) {
  return a * a;
}
int const INF = 100 + (int)1e9;
long long const INFL = 100 + (long long)1e18;
long double const PI = 3.1415926535897932384626433832795028;
int const D = 12012;
int const N = 1010;
pair<int, long long> dp[N][D];
int prev[N][D];
long long ds[D];
int const DV = (1 << 20) - 1;
vector<pair<long long, int>> dv[DV + 4];
int ind(long long x) {
  int i = x & DV;
  return lower_bound(dv[i].begin(), dv[i].end(), make_pair(x, -1))->second;
}
void solve() {
  int n;
  long long k;
  scanf(
      "%d"
      "%lld",
      &n, &k);
  int sz = 0;
  for (int i = 1; (long long)i * i <= k; ++i) {
    if (k % i == 0) {
      ds[sz++] = i;
      if ((long long)i * i < k) {
        ds[sz++] = k / i;
      }
    }
  }
  sort(ds, ds + sz);
  for (int i = 0; i < sz; ++i) {
    dv[ds[i] & DV].emplace_back(ds[i], i);
  }
  fill(dp[0], dp[0] + sz, make_pair(INF, INFL));
  dp[0][ind(1)] = {0, 0};
  long long mi = INFL;
  int mi_i = -1;
  for (int it = 0; it < n; ++it) {
    long long x;
    scanf("%lld", &x);
    if (mi > x) {
      mi = x;
      mi_i = it;
    }
    copy(dp[it], dp[it] + sz, dp[it + 1]);
    fill(prev[it + 1], prev[it + 1] + sz, -1);
    for (int i = 0; i < sz; ++i) {
      int j = ind(gcd(x, k / ds[i]) * ds[i]);
      pair<int, long long> cur = {dp[it][i].first + 1, dp[it][i].second + x};
      if (dp[it + 1][j] > cur) {
        dp[it + 1][j] = cur;
        prev[it + 1][j] = i;
      }
    }
  }
  if (k == 1) {
    printf("1\n%d\n", mi_i + 1);
    return;
  }
  if (dp[n][ind(k)].first == INF) {
    puts("-1");
    return;
  }
  static int ans[N];
  int cn = 0;
  int d = ind(k);
  for (int i = n; i > 0; --i) {
    if (prev[i][d] >= 0) {
      ans[cn++] = i;
      d = prev[i][d];
    }
  }
  printf("%d\n", cn);
  for (int i = 0; i < cn; ++i) {
    printf("%d ", ans[i]);
  }
  puts("");
}
int main() {
  cout.precision(15);
  cout << fixed;
  cerr.precision(6);
  cerr << fixed;
  solve();
}