[Tutor] more newbie questions

Kirby Urner urnerk@qwest.net
Wed, 1 May 2002 10:13:57 -0400


On Wednesday 01 May 2002 09:39 am, Lloyd Kvam wrote:
> Thanks.  An interesting read.
>
> I think Python2.2 helps greatly on the overflow front. int * int will
> now return a long when necessary.

True. =20

Another aspect of Tim's approach which makes it faster is
it doesn't allow the factorial in the numerator to build up=20
so high before dividing.  It's a more divide-as-you-go=20
approach that potentialy avoids a huge long/long at the end.

Kirby

> > Check this post by Tim Peters (archives, edu-sig) for
> > an optimized version of combo:
> >
> > http://aspn.activestate.com/ASPN/Mail/Message/580860