You are viewing a single comment's thread. Return to all comments →
from math import exp,factorial def thnks_for_the_fish(machine, cost): return sum((exp(-machine) * machine**k) / factorial(k) * (cost + 40 * k**2) for k in range(20)) A,B = map(float,input().split(" ")) print(round(thnks_for_the_fish(A, 160), 3)) print(round(thnks_for_the_fish(B, 128), 3))
Seems like cookies are disabled on this browser, please enable them to open this website
Day 5: Poisson Distribution II
You are viewing a single comment's thread. Return to all comments →