Dr. Pinter's A Book of Abstract Algebra presents the following exercise in the "Cyclic Groups" chapter.
List the elements of $\langle f\rangle$ in $S_6$ where $f$ =
$$(1 \rightarrow 6,2 \rightarrow 1, 3 \rightarrow 3, 4 \rightarrow 2, 5 \rightarrow 5, 6 \rightarrow 4)$$
I applied $f$ to $f$ until I reached $(1 \rightarrow 1, 2 \rightarrow 2, \dots)$. In other words, once the input's image, i.e. output, equaled itself. Finally I stopped since there's no more elements, as I understand.
At $f_4$, I arrived at this condition, i.e. where each input mapped to its output. Does that mean its elements are $f$, $f_2$, $f_3$, and $f_4$?
Note the chain $1\to6\to4\to2\to 1$. Note also that $3$ and $5$ are fixed elements of $f$. That means that when you apply $f$ four times (and not before), everything is at its original position, that is, $f^4=e$.
Then, $$\langle f\rangle=\{e,f,f^2,f^3\}$$