#include <bits/stdc++.h>
using namespace std;
pair<int, int> P[105];
int has[105];
int main() {
  int n, w;
  scanf("%d %d", &n, &w);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &P[i].first);
    P[i].second = i;
  }
  sort(P + 1, P + n + 1, greater<pair<int, int> >());
  int sum = 0;
  for (int i = 1; i <= n; i++) {
    sum += P[i].first / 2;
    has[i] = P[i].first / 2;
    if (P[i].first % 2 == 1) sum++, has[i]++;
  }
  if (sum > w) {
    printf("-1");
    return 0;
  }
  for (int i = 1; i <= n; i++) {
    if (sum == w) break;
    if (P[i].first - has[i] >= w - sum) {
      has[i] += w - sum;
      sum = w;
    } else {
      sum += P[i].first - has[i];
      has[i] = P[i].first;
    }
  }
  int ans[105];
  if (sum < w)
    printf("-1");
  else {
    for (int i = 1; i <= n; i++) ans[P[i].second] = has[i];
    for (int i = 1; i <= n; i++) printf("%d ", ans[i]);
  }
}
