#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a, b, c;
  while (cin >> n >> a >> b >> c) {
    int s = a + b + c;
    double ans = (1.0 * n / s);
    if (a == 0 && b == 0 && c == 0)
      printf("%.1lf %.1lf %.1lf\n", 0.0, 0.0, 0.0);
    else
      printf("%.16f %.16f %.16f\n", ans * a, ans * b, ans * c);
  }
  return 0;
}
