#include <bits/stdc++.h>
using namespace std;
struct node {
  int id;
  int v;
  int get;
} EE[105];
int cmp1(node A, node B) { return A.v > B.v; }
int cmp2(node A, node B) { return A.id < B.id; }
int main() {
  int n, w;
  scanf("%d%d", &n, &w);
  int sum = 0;
  int sumv = 0;
  for (int i = 1; i <= n; i++) {
    scanf("%d", &EE[i].v);
    EE[i].id = i;
    EE[i].get = EE[i].v / 2;
    if (EE[i].v % 2 == 1) EE[i].get++;
    sum += EE[i].get;
    sumv += EE[i].v;
  }
  if (sum > w || sumv < w)
    printf("-1\n");
  else {
    int x = w - sum;
    sort(EE + 1, EE + 1 + n, cmp1);
    int k = 1;
    while (x) {
      if (EE[k].get + x <= EE[k].v) {
        EE[k].get += x;
        x = 0;
      } else {
        x -= EE[k].v - EE[k].get;
        EE[k].get = EE[k].v;
      }
      k++;
    }
    sort(EE + 1, EE + 1 + n, cmp2);
    for (int i = 1; i <= n; i++) {
      if (i != n)
        printf("%d ", EE[i].get);
      else
        printf("%d\n", EE[i].get);
    }
  }
}
