Solve $f(f(n))=n!$ What am I doing wrong here: ( n!=factorial  )
Find $f(n)$ such that $f(f(n))=n!$
$$f(f(f(n)))=f(n)!=f(n!).$$
So $f(n)=n!$ is a solution, but it does not satisfy the original equation except for $n=1$, why?
How to solve $f(f(n))=n!$?

You just found out that if $f(f(n)) = n!$, then also $f(n)! = f(n!)$. That does not means that any function that satisfies the latter equation is a valid $f$.
