New submission from andy ye <andy.ye...@gmail.com>:

data = 'abcddd'
# True
data.find('a', 0)

# False
data.find('a', start=0)


# document
class str(obj):

    def find(self, sub, start=None, end=None): # real signature unknown; 
restored from __doc__
        """
        S.find(sub[, start[, end]]) -> int
        
        Return the lowest index in S where substring sub is found,
        such that sub is contained within S[start:end].  Optional
        arguments start and end are interpreted as in slice notation.
        
        Return -1 on failure.
        """
        return 0

----------
assignee: docs@python
components: Documentation
files: 截屏2020-12-29 上午10.57.53.png
messages: 383949
nosy: andyye, docs@python
priority: normal
severity: normal
status: open
title: The string find method shows the problem
versions: Python 3.6
Added file: https://bugs.python.org/file49704/截屏2020-12-29 上午10.57.53.png

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue42776>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to