# How many ways of creating a PIN code with length of 6 are there? [closed]

How can i calculate the number of possible PIN codes that use only numbers 0-9 and have length are there? No rules,all numbers can be same or different

## closed as off-topic by TheGeekGreek, Namaste, Daniel W. Farlow, user296113, ShaileshAug 3 '17 at 0:07

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "This question is missing context or other details: Please improve the question by providing additional context, which ideally includes your thoughts on the problem and any attempts you have made to solve it. This information helps others identify where you have difficulties and helps them write answers appropriate to your experience level." – TheGeekGreek, Namaste, Daniel W. Farlow, user296113, Shailesh
If this question can be reworded to fit the rules in the help center, please edit the question.

• What have have you tried so far? – platty Aug 2 '17 at 20:42
• Hint: how many digits are there, and how do we count the ways a task can be done? – Sean Roberson Aug 2 '17 at 20:43
• Both of those are wrong. I have no idea where either of your answers came from. – lulu Aug 2 '17 at 20:45
• No, it isn't. first do it for length one though. – lulu Aug 2 '17 at 20:47
• give an example of a PIN code of length one – Yanko Aug 2 '17 at 20:48

The key is the multiplication principle: If a task can be done in $m$ ways and another in $n$ ways, the number of ways we can do both is $mn$.

The idea is that you're choosing a digit from $0$ to $9$ and constructing a six digit PIN. We can start with the case of one digit, then two, then I'll leave it to you to extend to six.

There are only ten one-digit PINs: $0, 1, 2, 3, 4, 5, 6, 7, 8, 9$. Ten digits.

What about two? We could list them out, but let's be smart: this is the same as the concatenation of two one-digit PINs. We have ten choices for the first digit and ten for the second. How many total two-digit PINs are there? By the multiplication prinicple, this is $10 \cdot 10 = 100$. There are a hundred possible 2-digit PINs.

Can you take it from here?

• 10 to the power of 6? – Murad Aug 2 '17 at 20:50
• Well done. That's exactly it. – Sean Roberson Aug 2 '17 at 20:50
• wow i'm a genius – Murad Aug 2 '17 at 20:51
• @Murad you are the most brilliant person I have ever met. – Yanko Aug 2 '17 at 20:51
• @yanko My math teacher tells me the same thing – Murad Aug 2 '17 at 20:52

Here is another way to see this

every Pin code of lenth 6 defines a number from 0 to 999,999, that is in total one million numbers.