#include <bits/stdc++.h>
using namespace std;
__int128 read() {
  __int128 x = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
void print(__int128 x) {
  if (x < 0) {
    putchar('-');
    x = -x;
  }
  if (x > 9) print(x / 10);
  putchar(x % 10 + '0');
}
__int128 gcd(__int128 a, __int128 b) { return b ? gcd(b, a % b) : a; }
__int128 ex_gcd(__int128 a, __int128 b, __int128& x, __int128& y) {
  if (b == 0) {
    x = 1;
    y = 0;
    return a;
  }
  __int128 d = ex_gcd(b, a % b, x, y);
  __int128 temp = x;
  x = y;
  y = temp - a / b * y;
  return d;
}
bool liEu(__int128 a, __int128 b, __int128 c, __int128& x, __int128& y) {
  __int128 d = ex_gcd(a, b, x, y);
  if (c % d != 0) return 0;
  __int128 k = c / d;
  x *= k;
  y *= k;
  return 1;
}
signed main() {
  __int128 n, p, w, d;
  n = read();
  p = read();
  w = read();
  d = read();
  __int128 x, y;
  if (!liEu(w, d, p, x, y)) return (std::cout << "-1\n", 0);
  __int128 t = d / gcd(w, d);
  __int128 xt = (x % t + t) % t;
  __int128 yt = (p - w * xt) / d;
  if (xt >= 0 && yt >= 0 && xt + yt <= n) {
    print(xt);
    printf(" ");
    print(yt);
    printf(" ");
    print(n - xt - yt);
    printf("\n");
    return 0;
  }
  t = w / gcd(w, d);
  yt = (y % t + t) % t;
  xt = (p - d * yt) / w;
  if (xt >= 0 && yt >= 0 && xt + yt <= n) {
    print(xt);
    printf(" ");
    print(yt);
    printf(" ");
    print(n - xt - yt);
    printf("\n");
    return 0;
  }
  std::cout << -1 << "\n";
  return 0;
}
