# How many valid passwords can be formed using the following rules?

(i) Passwords must be 2 characters long, and (ii) each character must be a lower-case letter(a-z) or a digit(0-9). (iii) Each password must contain at least one letter.

Letter: 26, Digits: 10

Should it be 26x26-10x10?

Can someone explain this to me, I confuse myself way to much.

• How many choices exist for the first character? Is it 26 possible or 36 possible? With this in mind, how many possible two-character passwords exist if we don't care about the third condition where each password must contain at least one letter? How many of those passwords were "bad" and violated the third condition? – JMoravitz May 8 '16 at 3:05

Since there are $26$ letters and $10$ digits, there are $26 + 10 = 36$ choices for each character. The number of two-character passwords that contain at least one letter is found by subtracting the number of passwords that contain only digits from the total number of possible passwords, which yields $36^2 - 10^2 = 1296 - 100 = 1196$.