Here is a code
$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
import numpy
import matplotlib.pyplot as plt
def p2(lam, n):
return lam ** n * numpy.exp(-lam) / numpy.math.factorial(n)
size = 20
xVec = [0] * size
plt.figure(figsize = (12, 4))
for x in range(size):
xVec[x] = p2(1, x)
plt.subplot(1, 3, 1)
plt.stem(xVec, markerfmt = ' ')
for x in range(size):
xVec[x] = p2(2, x)
plt.subplot(1, 3, 2)
plt.stem(xVec, markerfmt = ' ')
for x in range(size):
xVec[x] = p2(10, x)
plt.subplot(1, 3, 3)
plt.stem(xVec, markerfmt = ' ')
plt.show()
$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
i need to change code it to look like this:
offer: 200fg for help