The applet below serves a demonstration for the product of permutations. It displays two permutations, say f and g, of numbers 1, 2, ..., N in a circular arrangement and their product fg below. Recollect that, for 1 ≤ k ≤ N,
(fg)(k) = g(f(k)),
so that the left permutation is carried out first.
The elements of the two permutations are clickable: clicking on two elements in a sequence in either of the permutations multiplies that permutation by a transposition of the two elements.