#include <bits/stdc++.h>
using namespace std;
int main() {
  double s;
  cin >> s;
  double a, b, c;
  cin >> a >> b >> c;
  double sum = a + b + c;
  if (!sum) {
    cout << "1 0 0";
  } else {
    cout << fixed << setprecision(12);
    cout << (a * s) / sum << ' ' << (b * s) / sum << ' ' << (c * s) / sum;
  }
  return 0;
}
