Can the number have introductory zeros? Like 0000, 0001, 0002,...,0074,...0865?
Or must it start with 1 through 9? All digital codes I've seen allow them.
If it can have introductory zeros, then 0000 through 9999 is 10,000
is the maximum possible tries, if digits can be repeated
If it has to start with at least 1, then it's 10,000 minus these 1000:
(0000 through 0999). So it's 9000, if digits can be repeated.
Or you can consider it this way so you can use your calculator:
If it can have an introductory 0, like 0023, then it's
10 ways for the 1st digit, times 10 ways for the 2nd digit, times
10 ways for the 3rd digit times 10 ways for the 4th digit.
10×10×10×10 ENTER on the TI-84+ calculator. or
10^4 ENTER
or
2ND, LOG, 4, ), ENTER
If it cannot have an introductory 0, then it's 9 ways for the 1st digit,
times 10 ways for the 2nd digit, times
10 ways for the 3rd digit times 10 ways for the 4th digit.
9×10×10×10 ENTER on the TI-84+ calculator. or
9×10^3 ENTER
or
9, ×, 2ND, LOG, 4, ), ENTER
------------
When digits cannot be repeated:
If it can have an introductory 0, like 0748, then it's
10 ways for the 1st digit, times 9 ways for the 2nd digit, times
8 ways for the 3rd digit times 7 ways for the 4th digit.
You can do that on a TI-84+ either by
10×9×8×7 = 5040
or by
10, MATH, left arrow, 2, 4, ENTER
(you'll see 10 nPr 4)
If it cannot have an introductory 0, like 0748, then it's
9 ways for the 1st digit, times 9 ways for the 2nd digit, times
8 ways for the 3rd digit times 7 ways for the 4th digit.
You can do that on a TI-84+ either by
9×9×8×7 = 4536
or by
9,×,9, MATH, left arrow, 2, 3, ENTER
(you'll see 9×9 nPr 3)
Edwin