Commit 2c23ac27 by BellCodeEditor

save project

parent d0bebf0f
Showing with 6 additions and 6 deletions
#list_hero = ['赵一',30] # #list_hero = ['赵一',30]
#dict_hero = {'丁二':37} # #dict_hero = {'丁二':37}
#print(len(list_hero))##列表长度 # #print(len(list_hero))##列表长度
#print(len(dict_hero))##字典长度 # #print(len(dict_hero))##字典长度
name = input('你叫啥名呀?') # name = input('你叫啥名呀?')
power = int(input('你臂力多少呀?')) # power = int(input('你臂力多少呀?'))
list_hero = ['猴三',10,'猴一',21,'猴五',22,'猴队长',29,'猴七',30] list_hero = ['猴三',10,'猴一',21,'猴五',22,'猴队长',29,'猴七',30]
for i in range(len(list_hero)): for i in range(len(list_hero)):
if i % 2 == 1 and list_hero[i] >= power: if i % 2 == 1 and list_hero[i] >= power:
......
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