In this we are going to see a basic program to perform set multiplication in 2D array in Python Programming Language.
arr1 = [[1,3,5],[8,5,3],[1,7,4]]
arr2 = [[6,8,3],[9,8,2],[1,4,6]]
res = [[x, y] for x in arr1 for y in arr2 if x != y]
for i in res:
print(i)
#ENJOY CODING
Post a Comment
FOR ANY DOUBTS AND ERRORS FEEL FREE TO ASK. YOUR DOUBTS WILL BE ADDRESSED ASAP