str.find for multiple strings

Batista, Facundo FBatista at uniFON.com.ar
Wed Feb 11 19:23:44 CET 2004


Bart Nessux wrote:

#- x = str.find(temp, '120.50')
#- 
#- I am looking for '120.50' '120.51' '122.78' etc. How can I 
#- do this with 
#- just one str.find... I can use re if I must, but I'd like to 
#- avoid it if 
#- possible.

What do you want in return? Remember that "find" returns the position of the
string that you're looking for (or -1 if no match).

.	Facundo




More information about the Python-list mailing list