# Write a Python program to Row-wise element Addition in Tuple Matrix 
 # Python3 code to demonstrate working of 
# Row-wise element Addition in Tuple Matrix
# Using enumerate() + list comprehension
  
# initializing list
test_list = [[('Gfg', 3), ('is', 3)], [('best', 1)], [('for', 5), ('geeks', 1)]]
  
# printing original list
print("The original list is : " + str(test_list))
  
# initializing Custom eles
cus_eles = [6, 7, 8]
  
# Row-wise element Addition in Tuple Matrix
# Using enumerate() + list comprehension
res = [[sub + (cus_eles[idx], ) for sub in val] for idx, val in enumerate(test_list)]
  
# printing result 
print("The matrix after row elements addition : " + str(res)) 