Tuple Methods
count()
Returns the number of times a specified
value appears in the tuple.
Returns 0 if the value is not found.
Syntax – tuple.count(value)
Parameters:
value – Required – Any Data Type
The item to search for.
index()
Searches the tuple for a specified value and
returns the index of where it was found.
Raises an exception if the value is not found.
Syntax – tuple.index(value)
Parameters:
value – Required – Any Data Type
The item to search for