Nicer way of strip and replace?

Diez B. Roggisch deets at nospam.web.de
Tue Oct 11 18:03:11 EDT 2005


> I replace commata with dots, then delete leading/trailing "s then add to 
> a sum after converting it to a float.
> This looks ugly (I htink)  and I wonder if there is a nicer way to strip 
> commata and change the comma to a dot already when reading in.

It's not ugly - it's necessary.

> Or should i do it with a shell script before processing in python?

Which would make it less "ugly"?

Diez



More information about the Python-list mailing list