#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9 + 5;
const int MAXN = 100005;
const long long MOD = 1000000007;
const double eps = 1e-8;
const double PI = acos(-1.0);
long long gcd(long long a, long long b) { return b == 0 ? a : gcd(b, a % b); }
long long ppow(long long a, long long b) {
  long long res = 1;
  for (int i = 1; i <= b; i++) res *= a;
  return res;
}
long long quick_mod(long long a, long long b, long long c) {
  long long ans = 1;
  while (b) {
    if (b % 2 == 1) ans = (ans * a) % c;
    b /= 2;
    a = (a * a) % c;
  }
  return ans;
}
int main() {
  double t;
  int S;
  int a, b, c;
  while (scanf("%d", &S) != EOF) {
    scanf("%d%d%d", &a, &b, &c);
    if (a == 0 && b == 0 && c == 0) {
      printf("0 0 0\n");
      continue;
    }
    t = (double)S / double(a + b + c);
    printf("%.16lf %.16lf %.16lf\n", t * a, t * b, t * c);
  }
}
