#include <bits/stdc++.h>
using namespace std;
const int N = 100 + 10;
int n, w, ans[N], b[N];
pair<int, int> a[N];
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0), cout.tie(0);
  int ned = 0;
  cin >> n >> w;
  for (int i = 1; i <= n; i++) {
    cin >> a[i].first;
    a[i].second = i;
    ned += (a[i].first + 1) / 2;
  }
  if (ned > w) cout << -1, exit(0);
  sort(a + 1, a + n + 1);
  w -= ned;
  for (int i = 1; i <= n; i++) b[i] = (a[i].first + 1) / 2;
  for (int i = n; i >= 1; i--) {
    if (w > a[i].first - b[i])
      w -= a[i].first - b[i], b[i] = a[i].first;
    else
      b[i] += w, w = 0;
  }
  for (int i = 1; i <= n; i++) ans[a[i].second] = b[i];
  for (int i = 1; i <= n; i++) cout << ans[i] << " ";
}
