Discuss / Python / 小练习-毕生所学

小练习-毕生所学

Topic source

涵_天

#1 Created at ... [Delete] [Delete and Lock User]

死循环输出

player = [
    ['Lisa','Bob','Jeney'],
    ['Juli','Lusy','Candy'],
    ['Fancy','Mandy','John']
          ]
while (len(player)>0):
    for name in player:
        for name_ in name:
            print(name_)
    if len(player) == 1:
        player = [
    ['Lisa','Bob','Jeney'],
    ['Juli','Lusy','Candy'],
    ['Fancy','Mandy','John']
          ] 
    player.pop()


  • 1

Reply