Commit 87ec48d6 by BellCodeEditor

save project

parent 608a8bdf
Showing with 7 additions and 2 deletions
a='刘强' a='刘强'
b=66 b=66
liebiao=['张一',25,'李二',38,'王三',50,'周四',90,'孙五',93] liebiao=['张一',25,'李二',38,'王三',50,'周四',90,'孙五',93]
for i in range(len(liebiao)) for i in range(len(liebiao)):
if i%2==1a and if i%2==1 and liebiao[i]>b:
liebiao.insert(i-1,a)
liebiao.insert(i,b)
break
print(liebiao)
\ 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