oddness in string.find(sub,somestring)

Fredrik Lundh fredrik at pythonware.com
Wed Mar 30 06:52:19 EST 2005


"MyHaz" wrote:
>>>> searched_string=""
>>>> print string.find(substring,searched_string)
> 0
>>>>
>
> why would this be? And when is someone going to fix it :P

>>> substring[0:0+len(searched_string)] == searched_string
True

</F> 






More information about the Python-list mailing list