Answers for "unpacking of tuples in python"

0

Tuples unpacking

>>> b = ("Bob", 19, "CS")
>>> (name, age, studies) = b    # tuple unpacking
>>> name
'Bob'
>>> age
19
>>> studies
'CS'
Posted by: Guest on October-05-2021
0

unpacking of tuples in python

tuple1 = ("python","c#","c++")
(programming_language_1,programming_language_2,programming_language_3) = tuple1
print(programming_language_1, "n",programming_language_2,"n",programming_language_3)
Posted by: Guest on January-10-2022
0

unpacking tuples in python

>>> def f():
    return 1,2
>>> a,b=f()
>>> a
1
>>> b
2
Posted by: Guest on March-12-2021
0

tuple unpacking

count, fruit, price = (2, 'apple', 3.5)
Posted by: Guest on July-17-2021

Python Answers by Framework

Browse Popular Code Answers by Language