#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e2 + 5;
struct node {
  int id, a, ans;
  node() {}
  node(int id, int a, int ans) : id(id), a(a), ans(ans){};
} p[maxn];
int main() {
  int n, w;
  scanf("%d %d", &n, &w);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &p[i].a);
    p[i].id = i;
  }
  sort(p + 1, p + 1 + n, [](node& x, node& y) { return x.a < y.a; });
  for (int i = 1; i <= n; i++) {
    p[i].ans += (p[i].a + 1) / 2;
    w -= p[i].ans;
  }
  if (w < 0) {
    puts("-1");
    return 0;
  }
  for (int i = n; i >= 1; i--) {
    int tmp = min(w, p[i].a - p[i].ans);
    p[i].ans += min(w, tmp);
    w -= min(w, tmp);
  }
  sort(p + 1, p + 1 + n, [](node& x, node& y) { return x.id < y.id; });
  for (int i = 1; i <= n; i++) printf("%d ", p[i].ans);
  return 0;
}
