Thu, 8 Dec 2011 20:58:37
To: Python Tutor
Subject: [Tutor] how to find index of list with its value
Well, we all know to know the value when we have the index of a list. But how
can we find it in the reverse way...
say a listl=[1,2,3,4]
l[0]=1.but how can I find its addres
On 08/12/2011 15:28, surya k wrote:
Well, we all know to know the value when we have the index of a list.
But how can we find it in the reverse way... say a listl=[1,2,3,4]
l[0]=1.but how can I find its address with its value 1 ??
help ([])
...
index(...)
L.index(value, [start, [stop]])
On Thu, Dec 8, 2011 at 10:28 AM, surya k wrote:
>
> Well, we all know to know the value when we have the index of a list. But
> how can we find it in the reverse way...
> say a listl=[1,2,3,4]
> l[0]=1.but how can I find its address with its value 1 ??
> __
Well, we all know to know the value when we have the index of a list. But how
can we find it in the reverse way...
say a listl=[1,2,3,4]
l[0]=1.but how can I find its address with its value 1 ??
___
Tutor mailli