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