Articles → Python → Tuple Unpacking In PythonTuple Unpacking In PythonIn this article, we will create an example of tuple unpacking.Example Consider a list of tuples.list = [(1,2) , (3,4), (5,6)]Now, if we want to unpack tuples i.e., access each element of the list.list = [(1,2) , (3,4), (5,6)] for (a,b) in list: print(a,",",b)Output Posted By - Karan Gupta Posted On - Thursday, March 14, 2019 Query/Feedback Your Email Id** Subject* Query/Feedback Characters remaining 250**
list = [(1,2) , (3,4), (5,6)]
list = [(1,2) , (3,4), (5,6)] for (a,b) in list: print(a,",",b)
Query/Feedback