aa = []
for k in a:
    bb = []
for i in range(len(k[0]) - 1):
    cc = []
for j in range(len(k)):
    cc.append('!'.join([k[j][0], k[j][i + 1]]))
bb.append('.'.join(cc))
aa.append(' * '.join(bb))
b = ' , '.join(aa)
print(b)
Merging numpy array elements using join() in python