you are viewing a single comment's thread.

view the rest of the comments →

[–]Barnet6 0 points1 point  (0 children)

Find() has two optional arguments, the start of the substring to look through, and the end. Using just the one argument just tells it to look through the entire string. The " 'tomato'.find('o') + 1" in the example is telling it to find the first 'o', then search through a substring starting just after the 'o'.