#include <bits/stdc++.h>
using namespace std;
int main() {
  double S;
  double a, b, c;
  cin >> S;
  cin >> a >> b >> c;
  double k = S / (a + b + c);
  if (a == 0 and b == 0 and c == 0)
    printf("%f %f %f", 0, 0, 0);
  else
    printf("%.36lf %.36lf %.36lf", a * k, b * k, c * k);
  return 0;
}
