最新回答 / 翎栋
# -*- coding: utf-8 -*-# 加上上面这个注释就可以带有中文的注释了b = "Python"print("Life is short, you need {c}".format(c=b))print("Life is short, you need {0}".format("Python"))# no chinese world or
2024-01-11
最赞回答 / 翎栋
L = [75, 92, 59, 68, 99]def avg(l): return sum(l) / len(l)def avg2(l): sum1 = 0 for i in l: sum1 += i return sum1 / len(l)average = avg2(L)print(average)
2023-12-19