Rohit provides one of two crucial distinctions that you did not provide in
your original problem statement: repeats allowed (=> "exponential
counting") or no ("factorial counting")? The other unprovided crucial
distinction: order matters (=> "permutations") or no ("combinations"),
i.e., is "abc" to be considered the same as "bca" or not?
DG
On Mon, Oct 15, 2012 at 12:00 PM,
<[email protected]>wrote:
> Send seattle-python mailing list submissions to
> [email protected]
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.seapig.org/mailman/listinfo/seattle-python
> or, via email, send a message with subject or body 'help' to
> [email protected]
>
> You can reach the person managing the list at
> [email protected]
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of seattle-python digest..."
>
>
> Today's Topics:
>
> 1. Re: Can you verify a math problem for me? (Kevin LaTona)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Sun, 14 Oct 2012 21:50:15 -0700
> From: Kevin LaTona <[email protected]>
> To: Seattle Python Interest Group <[email protected]>
> Subject: Re: [SEAPY] Can you verify a math problem for me?
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=WINDOWS-1252; format=flowed;
> delsp=yes
>
>
>
> Interesting seems you just gave me plenty of extra headroom with this
> idea.
>
> Thanks all for your thoughts.
>
> -Kevin
>
>
>
>
> On Oct 14, 2012, at 5:30 PM, Rohit Patnaik wrote:
>
> > If you take the characters a-z and the numbers 1-9, you have 35
> > characters, yes. When you use them in a sequence of up to 3
> > characters, you have:
> > ? 35 + 35^2 + 35^3 = 44,135 sequences
> > Then, if you take three of those sequences, and allow repeats, you
> > have
> > ? 44,135^3 = 85970488160375 possible triplets
> > If you don't allow repeats, you have:
> > ? 44,135 * 44,134 * 44,133 = 85964644553970 possible triplets.
> > At least, that's what I get, using my admittedly rusty knowledge of
> > combinatorics.
> >
> > Thanks,
> > Rohit Patnaik
> >
> > On Sun, Oct 14, 2012 at 5:19 PM, Kevin LaTona <[email protected]>
> > wrote:
> > I am working on a weekend project idea and was wondering if anyone
> > on the list could verify a math problem for me?
> >
> >
> >
> > Here is the problem.
> >
> > If one takes the characters a-z and numbers 1-9 this gives one 35
> > possible character options.
> >
> > Now if used in a sequence of up to 3 characters.
> >
> > I get a total of 6,545 possible combinations of these 35 characters.
> >
> >
> >
> > Now if one was to use them in file folder tree style structure such
> > as,
> >
> > ad6 / 7gh / d8s
> >
> > My math shows there is 46,706,638,440 possible combinations of these
> > 35 characters in a 3 layer deep tree.
> >
> > Do you get the same results or am I doing something wrong here?
> >
> > Thanks your thoughts on the matter.
> > -Kevin
> >
> >
> >
> >
> > This is the rather quick and dirty Python code I used to get to
> > these results today.
> >
> > import math
> >
> > a = math.factorial(35)
> > b = math.factorial(35-3)
> > c = math.factorial(3)
> > d = a / (b*c)
> > '{:,}'.format(d)
> > #'6,545'
> >
> >
> > e = math.factorial(6545)
> > f = math.factorial(6545-3)
> > g = math.factorial(3)
> > h = e / (f*g)
> > '{:,}'.format(h)
> > #'46,706,638,440'
> >
>
>
>
> End of seattle-python Digest, Vol 102, Issue 7
> **********************************************
>
--
>From "A Letter From The Future" in "Peak Everything" by Richard Heinberg:
"By the time I was an older teenager, a certain...attitude was developing
among the young people...a feeling of utter contempt for anyone over a
certain age--maybe 30 or 40. The adults had consumed so many resources,
and now there were none left for their own children...when those adults
were younger, they [were] just doing what everybody else was doing...they
figured it was normal to cut down ancient forests for...phone books, pump
every last gallon of oil to power their SUV's...[but] for...my generation
all that was just a dim memory...We [grew up] living in darkness, with
shortages of food and water, with riots in the streets, with people begging
on street corners...for us, the adults were the enemy."
Want to *really* understand what's *really* going on? Read "Peak
Everything."