#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long n, p, w, d, y = -1, x = -1;
  cin >> n >> p >> w >> d;
  bool f1 = false, f2 = false, f3 = false;
  for (long long i = 0; i <= 1000000; ++i) {
    long long aux = (p - (i * d)) / w;
    if (aux * w + i * d == p && aux >= 0) {
      x = aux;
      y = i;
      break;
    }
  }
  if (x != -1 && y != -1) {
    long long res = n - (x + y);
    if (res >= 0) {
      cout << x << " " << y << " " << res << endl;
      f1 = true;
    }
  }
  if (!f1) {
    if (p % w == 0) {
      long long win = p / w;
      long long res = n - win;
      if (res >= 0) {
        cout << win << " " << 0 << " " << res << '\n';
        f2 = true;
      }
    }
  }
  if (!f2 && !f1) {
    if (p % d == 0) {
      long long win = p / d;
      long long res = n - win;
      if (res >= 0) {
        cout << win << " " << 0 << " " << res << '\n';
        f3 = true;
      }
    }
  }
  if (!f1 && !f2 && !f3) cout << -1 << '\n';
  return 0;
}
