#include <bits/stdc++.h>
using namespace std;
const int inf = 1 << 28;
const double INF = 1e12, EPS = 1e-9;
int s, a, b, c;
double x, y;
double func(double A, double B) {
  return (a * log(A)) + (b * log(B)) + (c * log(s - A - B));
}
double calc(double A) {
  double L = 0, R = s - A;
  for (int i = 0; i < 200; i++) {
    x = (L * 2 + R) / 3;
    y = (L + R * 2) / 3;
    if (func(A, x) < func(A, y))
      L = x;
    else
      R = y;
  }
  return func(A, x);
}
void run() {
  cin >> s >> a >> b >> c;
  double l = 0, r = s, p, q;
  for (int i = 0; i < 200; i++) {
    p = (l * 2 + r) / 3;
    q = (l + r * 2) / 3;
    if (calc(p) < calc(q))
      l = p;
    else
      r = q;
  }
  printf("%.10f %.10f %.10f\n", l, x, s - l - x);
}
int main() { run(); }
