J
Jon Nicoll
Hi All
I would like to be able to use regular expression searches to
determine the index(es) within a string where a match was found. ie.,
given
import re
def myFunc():
# to be written ;-)
the call
myfunc("abc", "abcdefabcabc")
would return (say) a list [0, 6, 9]
I can't see a straightforward way of doing this from reading the
Regular Expression HOWTO and the python docs; any
pointers/suggestions?
Thanks
Jon N
I would like to be able to use regular expression searches to
determine the index(es) within a string where a match was found. ie.,
given
import re
def myFunc():
# to be written ;-)
the call
myfunc("abc", "abcdefabcabc")
would return (say) a list [0, 6, 9]
I can't see a straightforward way of doing this from reading the
Regular Expression HOWTO and the python docs; any
pointers/suggestions?
Thanks
Jon N