#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1111;
const int INF = 0x7f7f7f7f;
int cases;
const double EPS = 1e-8;
inline int sgn(double a) { return a < -EPS ? -1 : a > EPS; }
int main() {
  double s, a, b, c;
  cin >> s >> a >> b >> c;
  if (!sgn(a) && !sgn(b) && !sgn(c)) {
    puts("1.0 0.0 0.0");
  } else {
    double ts = s / (a + b + c);
    printf("%.10f %.10f %.10f\n", a * ts, b * ts, c * ts);
  }
}
