Permutations with Repetition (example) Assume a box that contains $20$ colored balls.

\begin{align}
&amp;-Red: 2 \\
&amp;-Blue: 1 \\
&amp;-White: 4 \\
&amp;-Orange: 3 \\
&amp;-Black: 5 \\
&amp;-Yellow: 2 \\
&amp;-Green: 3
\end{align}
The possible ways to put all those $20$ in order are:
$$
N_{20}=\frac{20!}{2!1!4!3!5!2!3!}
$$
However, what if we want to pick only $5$ and put them in order? I tried picking ordered groups of $5$ out of $20$ but ended up double-counting. Any hints?
Strategy  

Notice that $5$ can be partitioned in the following ways.
\begin{align*}
5 &amp; = 5\\
  &amp; = 4 + 1\\
  &amp; = 3 + 2\\
  &amp; = 3 + 1 + 1\\
  &amp; = 2 + 2 + 1\\
  &amp; = 2 + 1 + 1 + 1\\
  &amp; = 1 + 1 + 1 + 1 + 1
\end{align*}
This allows us to consider cases.

Five balls of one color:  We must select the black balls, then fill all five positions with them.

Four balls of one color and one ball of a different color:  We have two choices for which color to use for the four balls of the same color.  Choose four of the five positions for that color.  Choose one of the other six colors to fill the remaining position.

Three balls of one color and two balls of a different color:  We can have four choices for which color to use for the three balls of the same color.  Choose three of the five positions for that color.  No matter which color we have used, we are left with five choices for the color to use for the two balls of the same color.  Those balls must fill the remaining two positions.

Three balls of one color and one ball each from two of the other colors:  We have four choices for which color to use for the three balls of the same color.  Choose three of the five positions for that color.  That leaves us with six colors from which to choose the remaining two colors.  Arrange those two distinct balls in the remaining two positions.

Two balls each of two colors and one ball from one of the other colors:  We have six choices for which colors to use for the two pairs of balls of the same color.  Choose two of the five positions for the selected color that appears first in an alphabetical list.  Choose of the the remaining three positions for the other selected color.  Choose one of the other five colors to fill the remaining position.

Two balls of one color and one ball each from three other colors:  We have six choices for which color to use for the pair.  Choose two of the five positions for that color.  Choose three of the remaining six colors.  Arrange those three distinct balls in the remaining three positions.

One ball from each of five colors:  Choose five of the seven colors.  Arrange the five distinct balls in the five positions.
Fine, here we have 20 balls they aren't identical (by means of color) and you want to pick only 5 from them, order them and find out in how many ways we can do that if yes . It is indeed a very big problem when you pick 5 from 20 we are also considering the probability of picking up balls (each of different colors). So we need to consider the probability of picking a red, blue, white, orange, black, yellow, green which will get quite complex and will split up eventually into many cases. We need to order them after this in order to find out answer for your question !!

[edit]: or as the comment suggests you can also use exponential generating functions to solve this in a much more easier way