a = ("John", "Charles", "Mike")
b = ("Jenny", "Christy", "Monica")
x = zip(a, b)
#use the tuple() function to display a readable version of the result:
print(dict(x))
Just got to know about zip() functions and knowing about I learnt that it returns zip object. Tested out using tuple() and list() to give it is readable form, returns in it as tuple for each element. But incase of dict() it returns in key-value pair. Would helpful for me get an explanation .
New contributor
user24663490 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.