66: Arrangements

How many ways can we arrange a set of numbers ?

Say take two numbers, we have two ways. 12 and 21.

Say take three numbers, we have six ways. 123, 132, 231,213,321,312.

Say take four numbers, we have twenty four ways.

1234,1243, 1324, 1342, 1423,1432

2134, 2143, 2314, 2341, 2431, 2413

3124, 3142, 3214, 3241, 3412, 3421

4123, 4132, 4213, 4231, 4312, 4321

So formula for writing a given set in all possible arrangements is n! where n is the number of elements in the set.

I will write pseudo code this all together.

6 thoughts on “66: Arrangements

  1. I didn’t teach my students permutations until 7th grade. So happy to see you have a crack at it already. Keep it up.

Leave a Reply

Your email address will not be published. Required fields are marked *