1
$\begingroup$

Suppose that a password must have at least $8$, but not more than $10$ characters, where each character in the password is either one of the $26$ lower case English letters, or one of the $10$ digits, or one of the $6$ special characters $∗, \gt, \lt, !, +, =$.

$(i)$ How many different passwords are there?

$(ii)$ How many of these passwords contain at least one occurrence of at least one of the special characters?

For part $(i)$, I think it's a total of $42$ characters therefore $42\choose10$ (no. of $10$ character passwords) minus $42\choose8$ (no. of $8$ character passwords) . For part $(ii)$, I've no idea.

I'd appreciate a bit of guidance.

$\endgroup$
3
  • $\begingroup$ Apologies, I shall rephrase $\endgroup$
    – aqibjr1
    Oct 16, 2015 at 18:02
  • 1
    $\begingroup$ Must the passwords have all distinct characters? $\endgroup$ Oct 16, 2015 at 18:07
  • $\begingroup$ I'm not too sure, I don't think so, the question isn't clear about this $\endgroup$
    – aqibjr1
    Oct 16, 2015 at 18:16

1 Answer 1

3
$\begingroup$

i) $42^8+42^9+42^{10}$

ii)$[42^8+42^9+42^{10}]-[36^8+36^9+36^{10}]$ (The total number of possible password minus those that contains none of the special characters)

$\endgroup$
7
  • $\begingroup$ let A be the set of all the password, let B be the set of all the password that contains at least one special character. Then $ B=A-B^c$ $\endgroup$ Oct 16, 2015 at 18:10
  • $\begingroup$ If you wanted to select the no. of ways you can choose 8 characters from 42, would it not be 42C8? And therefore the answer be 42C8+42C9+42C10? $\endgroup$
    – aqibjr1
    Oct 16, 2015 at 18:11
  • $\begingroup$ The order matters here, and it is with repetition. $\endgroup$ Oct 16, 2015 at 18:13
  • $\begingroup$ When you say 42C8, you are assuming that the order doesn't matter, and it is without repetition. $\endgroup$ Oct 16, 2015 at 18:14
  • $\begingroup$ Ah okay, I get why repetition would be allowed, but surely the order of the characters in the password wouldn't? $\endgroup$
    – aqibjr1
    Oct 16, 2015 at 18:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.