How to join two tuples in Python

1 Answer

0 votes
tpl1 = ("Python", "Java", "PHP")
tpl2 = ("a", "b", "c", "d", "e")

jt = zip(tpl1, tpl2)

print(tuple(jt))


'''
run:

(('Python', 'a'), ('Java', 'b'), ('PHP', 'c'))

'''

 



answered Dec 18, 2018 by avibootz

Related questions

2 answers 243 views
2 answers 454 views
1 answer 248 views
248 views asked Dec 18, 2018 by avibootz
1 answer 332 views
1 answer 259 views
3 answers 330 views
...