Permutations and Combinations

Permutations are all the possible ways in which elements in a set can be arranged, here the order is important while Combinations are very similar to permutations, but here the order is not important. The main difference between both is order.

Permutations

Permutations Formula

Where n is the size of the set and k is the size of the subset

Let’s take an example, suppose we have four letters A, I, S, H and we want to arrange them in a pair in order. so, this is the problem of permutation as the order is important in the arrangement.

Permutations of A, I, S, H are: AI, AS, AH, IA, IS, IH, SA, SI, SH, HA, HI, HS

We have n = 4 as it is the size of the set which is (A, I, S, H) and k = 2 as we have to arrange elements in a pair.

Therefore, the total number of permutations for this set is 12.

Combinations

Combinations Formula

Where n is the size of the set and k is the size of the subset

Let’s take the same example, suppose we have four letters A, I, S, H and we want to arrange them in a pair where the order is not important. so, this is the problem of combinations as the order is not important in the arrangement.

Combinations of A, I, S, H are: AI, AS, AH, IS, IH, SH

We have n = 4 as it is the size of the set which is (A, I, S, H) and k = 2 as we have to arrange elements in a pair.

Therefore, the total number of combinations for this set is 6.

Hope this helps you in understanding the difference between permutations and combinations :)

Data Scientist