Counting problem?

  • Thread starter cragar
  • Start date
  • #1
2,544
3

Homework Statement


A software company uses a 20 character product key that new buyers of their
product must use during installation to successfully install the software in their
computers. The structure of these product keys is as follows. Repetitions are
allowed unless explicitly forbidden. Reading from left to right
(1) The first five characters must be capital letters from the western alphabet;
(2) The second five characters must include at least two of the digits 0, 1, 2, 3,
4, 5, 6, 7, 8, 9, and must include at least one capital letter;
(3) The third five characters are unrestricted - they may be digits or they may
be capital letters;
(4) The final five characters must include an 8.

The Attempt at a Solution


1) [itex] 26^5 [/itex]
2) On this one I will take the total number of combinations and subtract the combinations that just have letters in them to leave me with the total number of combinations that have numbers in them, then i need to subtract the combinations that just have one number so i can make sure my combinations have at least 2 numbers
[itex] 36^5-26^5-26^4*10 [/itex]
3) [itex] 36^5 [/itex]
4) [itex] 36^4 [/itex]
because I have 1 choice for one slot and then 36 on the rest.
 

Answers and Replies

  • #2
lanedance
Homework Helper
3,304
2
on the right track... but i think you need to be careful with 2) and 4) on:
- a couple of ordering assumptions
- some cases in line with wording
- accounting for counting repeated sequences


1) 5 letters only repetition ok
= = 26^5


2) Letters and numbers with at least 2 digits and one letter
- no restrictions = 36^5
- minus all letters = 26^5
- minus one number only = 5*10*26^4*10 - choose position of number(5), number(10) and then 4 ordered letters(26^4)
- minus all numbers = 10^5
 
  • #3
2,544
3
now i think the answer to 4 should be [itex] 36^5-35^5 [/itex]
because I am taking all the possible combos and subtracting the ones that don't have any 8's in them which would give me 35 choices.
and then on 2) like what you are saying .
take all possible combos subtract all letters then all numbers then subtract the ones with letters and one number.
so #2 should be [itex] 36^5-26^5-10^5-26^5(10) [/itex]
 
Last edited:
  • #4
2,544
3
could someone verify my count.
 
  • #5
2,544
3
I was just wondering if my count was right
 
  • #6
lanedance
Homework Helper
3,304
2
4) looks ok

2) looking at the cases that are not allowed
CASE A - letters only (<2numbers)
- 26^5 choices of ordered letter combinations
CASE B - one number only (<2 numbers):
- 5 choices for the position of the number
- 10 choices for the number
- 26^4 for the ordered letter combination
CASE C - numbers only (<1 letter)
- 10^5 choices of ordered number combinations
 

Related Threads on Counting problem?

  • Last Post
Replies
2
Views
1K
  • Last Post
Replies
4
Views
1K
  • Last Post
Replies
8
Views
1K
  • Last Post
Replies
1
Views
870
  • Last Post
Replies
3
Views
1K
  • Last Post
Replies
0
Views
915
  • Last Post
Replies
10
Views
2K
  • Last Post
Replies
19
Views
1K
  • Last Post
Replies
4
Views
1K
  • Last Post
Replies
8
Views
1K
Top