Hello, I need help, I cant remember my cell phone pin i set last night. It is a four digit number using numbers 0-9, the only thing i remember is it does contain 1 and 3. How many possible combinations could there possibly be? I don't want to reset it, I will lose all my information.

Expert Answers

An illustration of the letter 'A' in a speech bubbles


There are `10^4` pins at all. Denote the set of pins that contain no 1's as `B_1` and that contain no 3's as `B_3.`

We'll use the formula `n(A uu B) = n(A)+n(B)-n(A nn B)` which is true for any finite sets, particularly for `B_1` and `B_3` (`n(())` means the number of elements).

The set of pins that contain 1 AND contain 3 is the complement of those which don't contain 1 OR don't contain 3, i.e. `(B_1 uu B_3)^C.` The number of pins in this set is `10^4 - n(B_1 uu B_3).` By the above formula it is

`10^4 - (n(B_1)+n(B_3)-n(B_1 nn B_3)).`

It is clear that `n(B_1)=9^4` (any number except 1 at any of 4 positions), and `n(B_3)` is the same. `n(B_1 nn B_3)` is the number of pins that don't contain 1 AND don't contain 3, there are `8^4` of those (any number except 1 and 3 at any position).

So the answer is `10^4 - (9^4+9^4-8^4)=10^4+8^4-2*9^4 = 974.`

There are too many variants to try, it is necessary to recall the pin. Try the following trick: imagine that you want to set a new pin, what could it be?

Approved by eNotes Editorial Team

We’ll help your grades soar

Start your 48-hour free trial and unlock all the summaries, Q&A, and analyses you need to get better grades now.

  • 30,000+ book summaries
  • 20% study tools discount
  • Ad-free content
  • PDF downloads
  • 300,000+ answers
  • 5-star customer support
Start your 48-Hour Free Trial