[Tutor] str.strip strange result...?

Jignesh Sutar jsutar at gmail.com
Fri Jan 15 11:25:28 EST 2016


#python2.7

>>> s="V01_1"
>>> s.strip("_1")
'V0'


Wouldn't you expect the result to be "V01" ?


Cheers
Jignesh


More information about the Tutor mailing list