>>> s = 'foobar'
>>> s.find('z')
-1
>>> s.index('z')

Traceback (most recent call last):
  File "<pyshell#32>", line 1, in -toplevel-
    s.index('z')
ValueError: substring not found


Pretty self explanatory.

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to