Gapplet

Given a permutation in the form of a list, compute its cycle structure.


Input a permutation, 
e.g., [5,4,3,2,1]
 
 
The cycle structure