new string method in 2.5 (partition)

MonkeeSage MonkeeSage at gmail.com
Wed Sep 20 04:51:42 EDT 2006


s = "There should be one -- and preferably only one -- obvious way to
do it".partition('only one')
print s[0]+'more than one'+s[2]

;)

Regards,
Jordan




More information about the Python-list mailing list