#include <bits/stdc++.h>
using namespace std;
inline long long rd() {
  long long x = 0;
  int ch = getchar(), f = 1;
  while (!isdigit(ch) && (ch != '-') && (ch != EOF)) ch = getchar();
  if (ch == '-') {
    f = -1;
    ch = getchar();
  }
  while (isdigit(ch)) {
    x = (x << 1) + (x << 3) + ch - '0';
    ch = getchar();
  }
  return x * f;
}
inline void rt(long long x) {
  if (x < 0) putchar('-'), x = -x;
  if (x >= 10)
    rt(x / 10), putchar(x % 10 + '0');
  else
    putchar(x + '0');
}
const int maxn = 105;
int n, w, a[maxn], b[maxn], id[maxn];
bool cmp(int x, int y) { return a[x] > a[y]; }
int main() {
  n = rd(), w = rd();
  for (int i = 1; i <= (int)(n); i++) a[i] = rd(), id[i] = i;
  sort(id + 1, id + n + 1, cmp);
  for (int _ = 1, i = id[_]; _ <= n; _++, i = id[_]) {
    int need = (a[i] + 1) / 2;
    if (w < need) return puts("-1"), 0;
    w -= need, b[i] = need;
  }
  for (int _ = 1, i = id[_]; _ <= n && w; _++, i = id[_]) {
    int need = min(w, a[i] - b[i]);
    b[i] += need, w -= need;
  }
  for (int i = 1; i <= (int)(n); i++) rt(b[i]), putchar(' ');
}
