#include <bits/stdc++.h>
using namespace std;
long long mod = 1e9 + 7;
int main() {
  long double s, a, b, c;
  cin >> s >> a >> b >> c;
  if (a + b + c > 0)
    cout << fixed << setprecision(10) << (s * a) / (a + b + c) << ' '
         << (s * b) / (a + b + c) << ' ' << (s * c) / (a + b + c) << endl;
  else
    cout << fixed << setprecision(10) << s << ' ' << 0 << ' ' << 0 << endl;
  return 0;
}
