def setup():
m1=[[1,2,3],[4,5,6]]
m2=[[7,8,9],[10,11,12]]
addMatrix(m1,m2)
def showMatrix(a):
i=0
while(i<len(a)):
print(a[i])
i=i+1
def addMatrix(a,b):
i=0
while(i<len(a)):
j=0
while(j<len(a[i])):
print(a[i][j]+b[i][j]," ",end = "")
j=j+1
i=i+1
print("")
setup()
ไม่มีความคิดเห็น:
แสดงความคิดเห็น