#include <bits/stdc++.h>
using namespace std;
float S, a, b, c;
int main() {
  ios ::sync_with_stdio(false);
  cin >> S >> a >> b >> c;
  float sum = a + b + c;
  if (sum == 0)
    cout << "0 0 0";
  else
    printf("%.12f %.12f %.12f", a * S / sum, b * S / sum, c * S / sum);
  return 0;
}
