Dear list,

I have enjoyed the convenience to output any object with str(obj) for a 
while. However, I get long output for things like str([0.0002]) in my 
output (which bothers my users more than me though). I also do not 
understand why the following is happening:

 >>> str([0.0002])
'[0.00020000000000000001]'
 >>> str(0.0002)
'0.0002'

Is there any way to fix this, other than checking the type of everything 
and output with %.4f?

Many thanks in advance.
Bo
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to