Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #87037 > unrolled thread

Re: Speeding up permutations generation

Started byDave Angel <davea@davea.name>
First post2015-03-06 11:30 -0500
Last post2015-03-06 11:30 -0500
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Speeding up permutations generation Dave Angel <davea@davea.name> - 2015-03-06 11:30 -0500

#87037 — Re: Speeding up permutations generation

FromDave Angel <davea@davea.name>
Date2015-03-06 11:30 -0500
SubjectRe: Speeding up permutations generation
Message-ID<mailman.118.1425659413.21433.python-list@python.org>
On 03/06/2015 11:14 AM, Gene Heskett wrote:
>
>
> On Friday 06 March 2015 06:22:34 Dave Angel wrote:

>>
>> Sorry, but 50! is not even close to 50**50.  The latter is 85 digits
>> as you say, but 50! is "only" 64.
>>
>>
>> 30414093201713378043612608166064768844377641568960512000000000000L
>
> What utility output that as an L ?
>

Python 2.7 interpreter, after calculating factorial with the obvious 
loop.  Basically, it's using repr() on the expression, so it flags the 
integer as a long, rather than an int.

I debated not including it, but this way I was sure of getting the right 
number of zeroes.  My copy/paste is notorious for missing a character or 
two at each end.

-- 
DaveA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web