(Discrete) Probability is essentially about counting. Counting the number of ways an outcome from a random experiment can happen. We need some tricks to help us. π
Permutations
A permutation of a set is an ordering of the set. If you have N elements in a set and you change the order you have another permutation.
Example 1.
Consider the set A={1,2,3}. We can re-arrange the items in a set to form the following permutations
(1,3,2)(1,3,2)(2,1,3)(2,3,1)(3,1,2)(3,2,1)
We have 3!=3β2β1=6 permutations (see next example for why this is the case)
The symbol N! (factorial) means N(Nβ1)β¦1

Example 2.
Permutations of N different items.
If you have N different hats how many ways of ordering them are there? There are N ways to choose the first hat, N-1 ways to choose the second hat and so on.
We have in total N(Nβ1)β¦1=N! ways of ordering the hats.

Example 3.
Permutations with Repetition.
Suppose you N hats, K black and N-K red. Apart from the colour they are indistinguishable. How many ways of ordering them are there? We know from above N! if they are all different. However (N-K)! are indistinguishable (permutations of red hats) and K! are indistinguishable (permutations of black hats). Hence there are
N!K!(NβK)! orderings
Combinations
A combination of a set, A, is a subset of A, and unlike permutations above the order does not matter. An example will make this clearer.
Example 4.
Letβs suppose A={1,2,3}. Then the following sets are all the combinations of A
{1,2}{2,3}{3,1}{1}{2}{3}{1,2,3}β
You will notice there are 8 of them as each element in A can be chosen or not chosen for the combination ( 2 choices) and there are three elements in A all together so there are in total 23=8 combinations.
To be more specific, subsets of size K are called K-combinations. Note that the sets {1,2} and {2,1} are the same 2-combination (subset) as changing the order of the elements does not create a new combination.
Lets concentrate on creating a K-combination of a set of N (distinct) elements. Note we donβt actually have to bother with the word distinct because by definition a mathematical set contains distinct elements.
Example 5.
K-combinations of an N-set
Suppose A={1,2,3,4} write down all the possible 3-combinations.
{1,2,3}{2,3,4}{3,4,1},{4,1,2}
If we wanted to create all the permutations of subsets of A of size 3 we would have 4 choices for the first item, 3 choices for the second item and 2 choices for the third item i.e. 4*3*2 permutations in total. Each one of those sets above has 3! permutations as in example 1 since they contain 3 elements so that we know the number of combinations is 4β3β23! or 4!(4β3)!3!. In general the number of K-combinations from a set of size N is N(NβK)!K!
N(NβK)!K! is such an important formula it has its own notation.
C(N,K)=N(NβK)!K!
C(N,K) is sometimes also written as \binom{N}{K} and pronounced βN choose Kβ.