My textbook says (without explaining how it is done): $$\begin{pmatrix} 1\ 2\ 3\ 4\\ 2\ 1\ 4\ 3 \end{pmatrix}\begin{pmatrix} 1\ 2\ 3\ 4\\ 2\ 3\ 4\ 1 \end{pmatrix}=\begin{pmatrix} 1\ 2\ 3\ 4\\ 3\ 2\ 1\ 4 \end{pmatrix},$$ and as I understand this is obtained by doing calculations from left to right, but as I read here and elsewhere it should be done from right to left, like function composition...
So what i got is: $\begin{pmatrix} 1\ 2\ 3\ 4\\ 2\ 1\ 4\ 3 \end{pmatrix}\begin{pmatrix} 1\ 2\ 3\ 4\\ 2\ 3\ 4\ 1 \end{pmatrix}=\begin{pmatrix} 1\ 2\ 3\ 4\\ 1\ 4\ 3\ 2 \end{pmatrix}$, or in cycle notation: $(1,2)(3,4)(1,2,3,4)=(2,4)$ am I right?
As Brian M. Scott has noted, it is a matter of convention.
Although possibly not natural at first, left-to-right has some advantages, especially when doing products of permutations in disjoint cycles form, if your mother language is left-to-right, because you compose as you read. Notice that you write your cycles left-to-right $$ \begin{pmatrix} 1\ 2\ 3\ 4\\ 2\ 3\ 4\ 1 \end{pmatrix} = (1234), $$ so if you try and do $$ (12)(34) \circ (1234) $$ first right-to-left and then left-to-right, you will notice the (admittedly very slight) difference in the work you do. Mind you, I don't want to convince you to shift allegiances, whatever works for you is fine, of course.
Must add that I am a group theorist at heart, and apparently the left-to-right virus is particularly virulent in my community.
Concerning the answer by Don Antonio, I decided long ago that my vectors were row vectors, so when I compose I have to put my matrices on the right.