题解 | #累加数与平均值#
累加数与平均值
https://www.nowcoder.com/practice/ed009465ad6940609542ef5879a0d697
list_num = list(int(x) for x in input().split(' ')) sum_n = 0 for num in list_num: sum_n += num print(f'{sum_n} %.1f' %(sum_n/len(list_num)))
累加数与平均值
https://www.nowcoder.com/practice/ed009465ad6940609542ef5879a0d697
list_num = list(int(x) for x in input().split(' ')) sum_n = 0 for num in list_num: sum_n += num print(f'{sum_n} %.1f' %(sum_n/len(list_num)))
相关推荐