#include <bits/stdc++.h>
using namespace std;
void solve(int n, int w) {
  vector<int> a(n);
  vector<int> b(n);
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < n; i++) {
    b[i] = a[i] / 2 + a[i] % 2;
    w -= b[i];
  }
  for (int i = 0; i < n && w > 0; i++) {
    int m = 0;
    bool chose = false;
    for (int k = 0; k < n; k++) {
      if ((a[k] > a[m] && b[k] < a[k]) || (!chose && b[k] < a[k])) {
        m = k;
        chose = true;
      }
    }
    int diff = a[m] - b[m];
    int x = ((diff < w) ? diff : w);
    b[m] += x;
    w -= x;
  }
  if (w != 0)
    cout << -1 << endl;
  else {
    for (int i = 0; i < n; i++) cout << b[i] << " ";
    cout << endl;
  }
}
int main() {
  int n, w;
  cin >> n;
  cin >> w;
  solve(n, w);
  return 0;
}
