the output of min('student') will be according to ASCII value? what are ASCII values here?
why am i getting an error?In [27]: person_tuple=(17,"Ram",56.8)In [28]: t2=("Student")In [29]: person_tupleOut[29]: (17, 'Ram', 56.8)In [30]: person_tuple + t2---------------------------------------------------------------------TypeError Traceback (most recent call last)<ipython-input-30-3714b9ddcd0d> in <module>----> 1 person_tuple + t2TypeError: can only concatenate tuple (not "str") to tuple
Can we convert a tuple to a string like we do for lists?
Nothing has been mentioned about how to convert string to tuple and vice-versa.
15777 visits
Outline:List, string and tuple sequence data types with examples How to access a list using index numbers? Access the string elements Access the tuple elements How to add different sequence data types? How to find the length of a variable? Find the sum of a list Convert list to tuple Convert tuple to list Convert string to list and list to string
List, string and tuple sequence data types with examples How to access a list using index numbers? Access the string elements Access the tuple elements How to add different sequence data types? How to find the length of a variable? Find the sum of a list Convert list to tuple Convert tuple to list Convert string to list and list to string
Show video info
Pre-requisite