import java.io.*;
import java.util.*;
public class Main {
public static void main
(String[] args
) { Scanner in
= new Scanner
(System.
in);
int n = in.nextInt();
int r = in.nextInt();
int sum = 0;
double S;
int[] x = new int[n];
for (int i = 0; i < n; i++)
x[i] = in.nextInt();
for (int i = 0; i < n; i++)
sum += x[i];
for (int i = 0; i < n; i++)
out.format("%.9f%n", (S / sum) * x[i]);
out.flush();
}
}
aW1wb3J0IGphdmEuaW8uKjsKaW1wb3J0IGphdmEudXRpbC4qOwogCnB1YmxpYyBjbGFzcyBNYWluIHsKCXB1YmxpYyBzdGF0aWMgdm9pZCBtYWluKFN0cmluZ1tdIGFyZ3MpIHsKCQlTY2FubmVyIGluID0gbmV3IFNjYW5uZXIoU3lzdGVtLmluKTsKCQlQcmludFdyaXRlciBvdXQgPSBuZXcgUHJpbnRXcml0ZXIoU3lzdGVtLm91dCk7CgkJCgkJaW50IG4gPSBpbi5uZXh0SW50KCk7CgkJaW50IHIgPSBpbi5uZXh0SW50KCk7CgkJaW50IHN1bSA9IDA7CgkJZG91YmxlIFM7CgkJaW50W10geCA9IG5ldyBpbnRbbl07CgkJZm9yIChpbnQgaSA9IDA7IGkgPCBuOyBpKyspCgkJCXhbaV0gPSBpbi5uZXh0SW50KCk7CgkJZm9yIChpbnQgaSA9IDA7IGkgPCBuOyBpKyspCgkJCXN1bSArPSB4W2ldOwoJCVMgPSBNYXRoLlBJICogciAqIHI7CgkJZm9yIChpbnQgaSA9IDA7IGkgPCBuOyBpKyspCgkJCW91dC5mb3JtYXQoIiUuOWYlbiIsIChTIC8gc3VtKSAqIHhbaV0pOwoJCQoJCW91dC5mbHVzaCgpOwoJfQp9