#include <bits/stdc++.h>
using namespace std;
int DEBUG = 0;
int Min(int a, int b) { return (a < b ? a : b); }
int Max(int a, int b) { return (a > b ? a : b); }
int Abs(int a) { return (a >= 0 ? a : -a); }
void print1d(int *vec, int M, const char *str = NULL) {
  if (str != NULL) printf("%s ", str);
  for (int i = 0; i < M; i++) {
    if (i > 0) printf(" ");
    printf("%d", vec[i]);
  }
  printf("\n");
}
int main(int argc, char **argv) {
  DEBUG = (argc >= 2) ? atoi(argv[1]) : 0;
  double S;
  int a, b, c;
  double x, y, z;
  cin >> S >> a >> b >> c;
  if ((a + b + c) == 0) {
    printf("%.16f %.16f %.16f\n", S / 3.0, S / 3.0, S / 3.0);
  } else {
    double abc = a + b + c;
    double k = S / abc;
    printf("%.16f %.16f %.16f\n", a * k, b * k, c * k);
  }
  return 0;
}
