#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 100;
int ans[maxn];
struct node {
  int id;
  int cap;
  int real;
};
node s[maxn];
bool cmp(node a, node b) { return a.cap > b.cap; }
int main() {
  ios::sync_with_stdio(false);
  int N;
  int K;
  cin >> N >> K;
  for (int i = 1; i <= N; i++) s[i].id = i, cin >> s[i].cap;
  sort(s + 1, s + 1 + N, cmp);
  for (int i = 1; i <= N; i++) {
    K -= (s[i].cap + 1) / 2;
    s[i].real = (s[i].cap + 1) / 2;
  }
  if (K < 0) {
    cout << -1 << endl;
    return 0;
  }
  for (int i = 1; i <= N && K != 0; i++) {
    if (K >= s[i].cap - s[i].real) {
      K -= s[i].cap - s[i].real;
      s[i].real = s[i].cap;
    } else {
      s[i].real += K;
      K = 0;
    }
  }
  for (int i = 1; i <= N; i++) ans[s[i].id] = s[i].real;
  for (int i = 1; i <= N; i++) cout << ans[i] << ' ';
  return 0;
}
