# Thread: The number of possible PIN numbers

1. ## The number of possible PIN numbers

This seems like a pretty straightforward question but I feel like I'm missing something.

Suppose I wanted to construct a pin number that contains 4 letters of the alphabet and 3 numbers (0 to 9) in no particular order, and I can use the same letter/number more than once.

My pin will be 7 letters/numbers in length.

I have:

(26)(26)(26)(26)(10)(10)(10)

= 456 976 000

It feels like I'm missing something or is the question really this straightforward?

Any help is appreciated!

2. That is correct!

3. So really, this is essentially the same thing if I wanted my pin number to start with 4 letters and then followed by 3 numbers? (I know this is a stupid question)

I don't have to divide out anything at all?

4. Originally Posted by DarK
So really, this is essentially the same thing if I wanted my pin number to start with 4 letters and then followed by 3 numbers? (I know this is a stupid question)

I don't have to divide out anything at all?
Your calculation counted the amount of pin numbers in the sequence LLLLDDD, where L is a letter and D is a digit,
allowing repetition.

That's fine if no shuffling of the letters among the digits is allowed.
(If you meant that the 4 letters are in direct sequence "in no particular order" and same for the digits).

5. So what if I could shuffle the letters and numbers in any way I want:

ie:

LDDLDLL
or
DLDLLDL
or
DDLLLDL

and so on

Would I have to account for this or would it just be the same calculation as my first post?

Thank you.

6. Originally Posted by DarK
So what if I could shuffle the letters and numbers in any way I want: ie: LDDLDLL or DLDLLDL
$\displaystyle \binom{7}{4}\left( {26^4 } \right)\left( {10^3 } \right)$

7. Originally Posted by Plato
$\displaystyle \binom{7}{4}\left( {26^4 } \right)\left( {10^3 } \right)$
Could somebody clarify, why are we multiplying by 7 choose 4?

8. Originally Posted by DarK
Could somebody clarify, why are we multiplying by 7 choose 4?

$\binom{7}{4}=\binom{7}{3}$

We choose 4 of the 7 positions for the 4 letters.
That automatically leaves us with 3 positions for the 3 digits.

Now you have $26^4$ alternatives for the letters and $10^3$ alternatives for the digits in that particular sequence.

the sequence could be LDLDLDL

Now choose a new sequence and you have the same $26^4$ alternatives for the letters and $10^3$ for the digits.

The number of such "letter-digit" sequences is $\binom{7}{4}=\binom{7}{3}$

as you need to choose 4 of the 7 positions for letters
or instead choose 3 of the 7 positions for the digits (same thing).

Hence you need to count the number of ways this can be done.

9. So it looks like the final answer can be either:

$\binom{7}{4}$ $26^4$ $10^3$

or

$\binom{7}{3}$ $26^4$ $10^3$

where the letters and numbers can take on any ordering.