a = [[0, 1, 2, 3], [0, 1, 2, 3], [0, 1, 2, 3], [0, 1, 2, 3]]
目前通过a可以获取如下格式:
[0,1,2,3]
[0,1,2,3]
[0,1,2,3]
[0,1,2,3]
现在想要通过a得到如下格式:
[0,0,0,0]
[1,1,1,1]
[2,2,2,2]
[3,3,3,3]
如何实现上面的要求?
本文出自 “长街听风人” 博客,请务必保留此出处http://kevinhao.blog.51cto.com/5204735/1793399
原文地址:http://kevinhao.blog.51cto.com/5204735/1793399