Gapplet

Let Mr be the monoid of all maps {1,...,r} -> {1,...,r}. If you input a sequence of elements, the submonoid of Mr generated by the sequence is computed.

Input a sequence of elements of Mr
e.g., [1,4,3,4,5,1], [ 6,6,3,3,1,1] in case r = 6
</COMMENT>
 
</COMMENT>
 
The elements of the submonoid of Mr generated by the input sequence.
</COMMENT>