Tuples
Tuples
Tuples are almost the same as lists but once the values are declared they can not be changed which means they are immutable. They are declared by brackets (). Trying to make changes in tuples gives you an error.
--------------------------------
Code: -
mytuple = ("python",9,"is",True,"awesome")
print(mytuple[0],mytuple[1],mytuple[2])
Output: -
python is awesome
-----------------------------------
Great work
ReplyDeleteNice Post and thank for sharing this content
ReplyDeleteServiceNow Developer Training Online
ServiceNow Developer Online Training