#include <bits/stdc++.h>
using namespace std;
pair<int, int> arr[100];
int res[100];
int main() {
  int N, W;
  scanf("%d%d", &N, &W);
  for (int i = 0; i < N; i++) {
    scanf("%d", &arr[i].first);
    arr[i].second = i;
  }
  sort(arr, arr + N);
  for (int i = 0; i < N; i++) {
    if (W < (arr[i].first + 1) / 2) {
      printf("-1\n");
      return 0;
    }
    W -= (arr[i].first + 1) / 2;
    res[arr[i].second] = (arr[i].first + 1) / 2;
  }
  int p = N - 1;
  while (W > 0) {
    int delta = min(W, arr[p].first - res[arr[p].second]);
    W -= delta;
    res[arr[p].second] += delta;
    p--;
  }
  for (int i = 0; i < N; i++) printf("%d ", res[i]);
  putchar('\n');
}
