task3
import math def func(x): f = ((math.e)**((-0.5)*(((x - m)/s)**2)))/(s*math.sqrt(2*(math.pi))) return f'{f:.8f}' m = 0 s = 2 x_lst = [1, 3, 5, 7, 9] for x in x_lst: print(f'x = {x}, f = {func(x)}')
标签:task3,return,lst,实验,func,math From: https://www.cnblogs.com/heqifan666/p/17477417.html