What are lists and tuples?
Question
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
It will take less than 1 minute to register for lifetime. Bonus Tip - We don't send OTP to your email id Make Sure to use your own email id for free books and giveaways
Answer ( 1 )
. The major difference is that a list is mutable, but a tuple is immutable. Examples:
1. >>> mylist=[1,3,3]
2. >>> mylist[1]=2
3. >>> mytuple=(1,3,3)
4. >>> mytuple[1]=2