Commit a58be0b3 by BellCodeEditor

auto save

parent 8d77c0f6
import turtle
pen=turtle.Pen()
pen.fillcolor("blue")
pen.begin_fill()
for i in range(5):
pen.fd(100)
pen.rt(360/5)
pen.end_fill()
pen.hideturtle()
turtle.done()
\ No newline at end of file
import random
jp=["小贝玩偶","iPad","小机器人","悟空玩偶"]
donejp=random.choice(jp)
name=input("你的名字叫什么?")
print("恭喜你,幸运的创造师——"+name+",获得了"+donejp)
\ No newline at end of file
students={'John':10,'Sam':11,'Lily':9,'Anna':10}
#print(students['Sam'])
if 'Lily' in students:
students['Lily']=10
#print(students['Lily'])
students['Sally']=11
#print(students['Sally'])
print(students)
\ No newline at end of file
menu={'红烧鱼':36,'手撕鸡':48,'烤鸭':56,'盐焗鸡':78,'时蔬':18,'米饭':3}
for a,b in menu.items():
print(a,b)
#menu.pop('烤鸭')
#print(menu)
#menu.clear()
#print(menu)
\ No newline at end of file
wkp={'数学':88,'英语':90,'语文':85}
nyp={'数学':93,'英语':90,'语文':89}
xbp={'数学':94,'英语':92,'语文':84}
k={'wk':wkp,'ny':nyp,'xb':xbp}
for a,b in wkp.items():
print(a,b)
print(nyp['语文'])
xbp['语文']=86
for c,d in k.items():
print(c,d)
\ No newline at end of file
while True:
a=input("请输入一个数")
b=input("请输入一个数")
c=input("请输入一个数")
try:
a=int(a)
b=int(b)
c=int(c)
except:
print("请输入整数")
else:
d=a+b+c
print(d)
\ No newline at end of file
import turtle
pen=turtle.Pen()
screen=turtle.Screen()
screen.bgcolor("blue")
talk=screen.textinput("提示","请输入祝福语:")
pen.write(talk,font=("Microsoft_Black",28,"normal"))
pen.hideturtle()
turtle.done()
\ No newline at end of file
i=0
while True:
i+=1
if i%3==0:
continue
else:
print(i)
if i==100:
break
\ No newline at end of file
for i in range(2,18,3):
print(i,end=" ")
\ No newline at end of file
name=['John','Sam','Lily','Anna','Helen']
name[2]="Nina"
name.insert(3,"Sally")
name1=['Daming','Neo','Sally']
name.extend(name1)
name.pop(1)
print(name[4:7])
print(name)
\ No newline at end of file
'''
text=['p','y','t','h','o','n']
text1="".join(text)
print(text1)
'''
text1='贝尔星球'
print(list(text1))
\ 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