#include <bits/stdc++.h>
using namespace std;
vector<pair<int, int> > v;
int ans[111];
int main() {
  int n, w;
  cin >> n >> w;
  for (int i = 0; i < n; i++) {
    int x;
    scanf("%d", &x);
    v.push_back(make_pair(x, i));
  }
  sort(v.begin(), v.end());
  for (int i = 0; i < n && w >= 0; i++) {
    int least = v[i].first / 2 + (v[i].first % 2 > 0);
    w -= least;
    ans[v[i].second] = least;
  }
  if (w < 0) {
    cout << "-1" << endl;
    return 0;
  }
  for (int i = n - 1; i >= 0; i--) {
    int r = min(w, v[i].first - ans[v[i].second]);
    w -= r;
    ans[v[i].second] += r;
  }
  for (int i = 0; i < n; i++) cout << ans[i] << " ";
  cout << endl;
  return 0;
}
