Extracting float from string

Peter Hansen peter at engcorp.com
Tue Jan 14 18:14:37 CET 2003

Spencer Ernest Doidge wrote:
> Good software engineering practice suggests that you always design for
> worst case. Usually I don't have to spell that out in discussions
> like this.

It wasn't clear from your posts that you knew the least thing about
software engineering.  In fact, there was a strong hint that you knew
very little about it.  Thanks for clarifying that you are an expert. (*)

In that case, use the re module, with changes as appropriate, as in
the first example you gave which had merely an integer instead of a
float.  Clearly you'll understand how to do this, as an expert in
the practice of software engineering.

* Good software engineering practice suggests that you always 
include requirements adequate to let your developers understand
what it is you need.  You might improve in this area, but as you
are an expert I'm sure you already knew that.

-Peter Hansen, P.Eng.
(Director of Software Engineering at my current employer...)

More information about the Python-list mailing list