标签:笔试 color col pytho style ima src inf 冒泡
‘‘‘冒泡排序‘‘‘ # coding:utf-8 list = [1, 13, 5, 35, 6, 9, 10] s = range(len(list))[::-1] print(s) for i in s: for j in range(i): if list[j] > list[j +1 ]: list[j], list[j + 1] = list[j + 1], list[j] print(list)
标签:笔试 color col pytho style ima src inf 冒泡
原文地址:https://www.cnblogs.com/yitao326/p/10557663.html