#include <bits/stdc++.h>
using namespace std;
ifstream in("f.in");
ofstream out("f.out");
int a, b, d, t, x, y;
int lgput(int a, int p, int mod) {
  int res = 1;
  while (p > 0) {
    if (p % 2 == 1) res = (1LL * res * a) % mod;
    a = (1LL * a * a) % mod;
    p /= 2;
  }
  return res;
}
int f(int n) {
  int r = 1, d = 2;
  while (n > 1) {
    int put = 0;
    while (n % d == 0) {
      n /= d;
      put++;
    }
    if (put != 0) r *= 1LL * (d - 1) * lgput(d, put - 1, 1000000007);
    d++;
    if (n > 1 && d * d > n) d = n;
  }
  return r;
}
int inversmodular(int a, int n) { return lgput(a, f(n) - 1, n); }
void precalc() { long long x = 1; }
void cer1() {
  int a, b, n;
  in >> a >> b >> n;
  precalc();
  cout << f(n);
}
vector<pair<int, int> > v;
int c[105];
int main() {
  int n, k;
  cin >> n >> k;
  int s = 0;
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    v.push_back(make_pair(x, i));
    s += (v[i].first + 1) / 2;
  }
  if (s > k) {
    cout << "-1";
    return 0;
  }
  k -= s;
  sort(v.begin(), v.end());
  for (int i = n - 1; i >= 0; i--) {
    c[v[i].second] = (v[i].first + 1) / 2;
    s = min(k, (v[i].first - (v[i].first + 1) / 2));
    k -= s;
    c[v[i].second] += s;
  }
  for (int i = 0; i < n; i++) cout << c[i] << " ";
  return 0;
}
