Python from Wise Guy's Viewpoint

Pascal Bourguignon spam at thalassa.informatimago.com
Wed Oct 29 11:26:20 EST 2003


Matthias Blume <find at my.address.elsewhere> writes:

> Pascal Costanza <costanza at web.de> writes:
> 
> > Computers are fast enough and have enough memory nowadays. You are
> > talking about micro efficiency. That's not interesting anymore.
> 
> I have worked on projects where people worried about *every cycle*.
> (Most of the time I agree with you, though.  Still, using infinite
> precision by default is, IMO, a mistake. 

What  are you  writing about?  Figments  of your  imagination or  real
concrete systems?


[20]> (typep (fact 100)  'fixnum)
NIL
[21]> (typep (fact 100)  'bignum)
T
[22]> (typep (/ (fact 100) (fact 99)) 'fixnum)
T
[23]> (typep (/ (fact 100) (fact 99)) 'bignum)
NIL
[24]> (/ 1 3)
1/3
[25]> (/ 1.0 3)
0.33333334

Where do you see "infinite precision by default"?


-- 
__Pascal_Bourguignon__
http://www.informatimago.com/




More information about the Python-list mailing list