I was using the lstrip to trim the left occurance of a string, and it
didnt seem to work for some cases. but when i investigated there does
seem to be an issue with some combination of strings
here is one case
 p1 = "abcd"
 p2 = 'def'                    # $abc
 sym = '_'
 str1 = p1 + sym + p2
 str1 = str1.lstrip(p1+sym)
 print str1                             # this prints ef instead of
def

can someone explain why this is happening ?
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to