Colourful Permutation Sorting

Gym - 103438H