newbie question structure of function

castironpi at gmail.com castironpi at gmail.com
Thu Mar 13 19:13:50 EDT 2008


Just some FYI options.

>     if not matchfilename:
May return positive if you someday return an object that holds a 'not'
value.

>     resultname="""
That starts a string literal.

>     if (matchdistance < threshold):
Parentheses optional.

>     return (matchdistance,resultname)
Parentheses optional there too.  "return matchdistance," returns a
'one-tuple'.




More information about the Python-list mailing list