Georg Brandl added the comment: round() does not return a string, but a floating point number, the best approximation to the "real" result that is achievable with the limited precision of binary floating point.
That result is then formatted to a string for display by the interactive interpreter using the repr() function, which formats a float with (I think) 17 decimal digits. So, the point here is that repr() produces "too many" digits for your liking ;) You can use str() to cut off at fewer digits, which will produce the "correct" string in most cases. __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue1559> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com