My question is:
Starting from Washington, DC, how many ways can you visit 5 of 50 state capitals and return to Washington?
I tried to solve it,
Firstly, we should choose 5 states from 50 countries which is C(50;5) and then I multiplied it with 5!
is my answer correct? Thanks.
Your answer is correct. The order in which the state capitals are visited matters, so this is a permutation.
There are $50$ ways of choosing the first state capital to visit, $49$ ways to choose the next state capital to visit, and so forth, giving
$50 \cdot 49 \cdot 48 \cdot 47 \cdot 46 = P(50, 5) = 5!C(50, 5)$
ways to visit $5$ of $50$ state capitals before returning to Washington, D.C.
Observe that
$$P(50, 5) = \frac{50!}{(50 - 5)!} = \frac{50!}{45!} = 5! \cdot \frac{50!}{5!45!} = 5!C(50, 5)$$
More generally,
$$P(n, k) = \frac{n!}{(n - k)!} = k! \cdot \frac{n!}{k!(n - k)!} = k!C(n, k)$$