Commit 1964a407 by BellCodeEditor

save project

parent abe115d9
Showing with 5 additions and 2 deletions
......@@ -3,12 +3,14 @@ power=int(input('你的臂力值是多少'))
list_hero=['猴三',10,'猴五',20,'猴七',30,'猴队长',60]
for i in range(len(list_hero)):
if i%2==1 and list_hero[i]>=power:
list_hero.insrt(i-1,name)
list_hero.insrt(i,power)
list_hero.insert(i-1,name)
list_hero.insert(i,power)
break
print(list_hero)
dict_hero={'猴三':10,'猴五':20,'猴七':30,'猴队长':60}
dict_hero['猴七']=32
dict_hero['猴十']=25
print(dict_hero)
\ 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