0
$\begingroup$

a. How many different 4 letter codes can there be?

b. What if letters cannot be repeated?

c. What if, in addition, 2 of the letters are x and y?

For a, it would simply be $26*26*26*26=456976$

For b, it would be $26*25*24*23=358800$

For c, it would be $24*23=552$

C seems a bit low to me but I think it makes sense

$\endgroup$
1
$\begingroup$

First, you assumed that there's exactly one x and one y in the code, whereas the problem doesn't state so.

I would interpret the "in addition" part of (C) to mean that the first two conditions hold.

If that is the case, then you choose two letters, which you did correctly. However, you then have to permute the $x, y$ and two letters chosen (this means you don't know where $x$ and $y$ are yet), which you can do in $4!$ ways. So your answer is $\binom{24}{2} * 4! = 24 * 24 * 23$.

$\endgroup$
1
  • $\begingroup$ Ah the latter part is very interesting. I did not think about it. Thank you! :) $\endgroup$ – atherton Apr 17 '14 at 0:01
2
$\begingroup$

Your answer to C is wrong. First, you assumed that there's exactly one x and one y in the code, whereas the problem doesn't state so. Second, x can occur on every position in the code, same for y. For example, there are 26*26 codes where two first letters are "xy" and 26*26 codes where "xy" are the 3rd and 4th letters, respectively.

Got A and B right.

$\endgroup$
1
  • $\begingroup$ But c states "what if, $\textit{in addition}..$ so in addition to condition b. And b states letters cannot be repeated $\endgroup$ – atherton Apr 16 '14 at 23:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.