2008/1/25, Jeffrey Yasskin <jyasskin at gmail.com>: > decision comes to be that int(float) should be blessed as a correct > way to truncate a float, I'd agree with Raymond that trunc() is just > duplication and should be eliminated. I'd, of course, rather have a > spelling that says what it means. :) Mmm... no. int() is a builtin way to transform the builtin data type float into the builtin data type float. There's no "correct" way for a float to become an integer, but in the math module you have several ways to do it (floor, ceil, round, trunc, choose the one that you want, but you're "notified" <wink/2> that there're different ways to do it). -- . Facundo Blog: http://www.taniquetil.com.ar/plog/ PyAr: http://www.python.org/ar/
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4