l1 = [4, 8, 12,16,3,7,11,15,2,6,10,14,1,5,9,13]
output :
[4,8,12,16]
[3,7,5,11]
[1,6,10,14]
[1,5,9,13]
m =4
n=4
tmp = [[0]*m]*n
a = 0
for i in range(m):
for j in range(n):
tmp[i][j] = l1[a]
a += 1
not printing in required format. What's wrong here ? Can you please help me.