Exercise 1.53 (Password problem)

Fred needs to choose a password for a certain website. Assume that he will choose an 8-character password, and that the legal characters are the lowercase letters a, b, c, . . . , z, the uppercase letters A, B, C, . . . , Z, and the numbers 0, 1, . . . , 9.
(a) How many possibilities are there if he is required to have at least one lowercase letter in his password?
(b) How many possibilities are there if he is required to have at least one lowercase letter and at least one uppercase letter in his password?
(c) How many possibilities are there if he is required to have at least one lowercase letter, at least one uppercase letter, and at least one number in his password?

Answers

(a)
628 368
(b)
628 368 368 + 108
(c)
628 368 368 108 + 2(628 368 528 + 268) + 628 368 368 + 108
User profile picture
2021-12-05 00:00
Comments

The solution to part C by fifthist x is wrong. An easy way to check it is that it sums up to greater than 62^8, which shouldn’t be the case since that is the total number of possibilities. We can get to the right answer by using three properties:

1. P(A) = 1 - P(Acomplement)

2. DeMorgan’s Law: AnB = AcomplementUBcomplement

3: Inclusion Exclusion formula

User profile picture
2023-11-19 06:34
Comments