Commit 42596ee7 by BellCodeEditor

save project

parent 270fa105
Showing with 12 additions and 3 deletions
import turtle
pen=turtle.Pen()
pen.write("Hi,诺依~\n用python写电子贺卡真是太有趣啦~\n———悟空",font=("Times",18,"normal"))
mc = {'语文':89,'数学':95,'英语':80}
def get_average(mc):
sum_mc = 0
for subject, mc in mc.items():
sum_mc += mc
print('现在的总分是%d'%sum_mc)
ave_mc = sum_mc/len(mc)
print('平均分是%d'%ave_mc)
get_average(mc)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment