#include <bits/stdc++.h>
using namespace std;
int vis[10000010] = {0};
int x[5050];
int main() {
  int b, k, i, j, q, m, n;
  memset(vis, 0, sizeof(vis));
  scanf("%d %d", &n, &k);
  for (i = 0; i < n; i++) {
    scanf("%d", &x[i]);
    vis[x[i]] = 1;
  }
  scanf("%d", &m);
  while (m--) {
    scanf("%d", &q);
    int ans = 0x3f3f3f3f;
    for (i = 1; i <= k; i++) {
      for (j = 0; j + i <= k; j++) {
        for (int l = 0; l < n; l++) {
          long long int s = i * x[l];
          if (s > q)
            continue;
          else {
            if ((j == 0 && s == q) ||
                (j != 0 && (q - s) % j == 0 && (q - s) / j <= 1e7 + 5 &&
                 vis[(q - s) / j] == 1)) {
              if (ans > j + i) ans = j + i;
            }
          }
        }
      }
    }
    if (ans != 0x3f3f3f3f)
      cout << ans << endl;
    else
      cout << "-1" << endl;
  }
  return 0;
}
