标签:算法基础 -- nbsp bsp 基础 enumerate index print 旋转
data=[[col for col in rang(4)] for row in rang(4)]
for row in data:
print(row)
print("-------------------------------------------")
for r_index, row in enumerate(data):
for c_index in range (r_index ,len(row)):
temp=data[c_index][r_index]
date[c_index][r_index]=row[c_index]
data[r_index][c_index]=temp
print("-----------------")
for r in data:print(r)
标签:算法基础 -- nbsp bsp 基础 enumerate index print 旋转
原文地址:http://www.cnblogs.com/my334420/p/6400932.html