I know that if $g(x)$ is periodic then $f(g(x))$ is periodic.
This is a sufficient condition but not necessary as $\sin(x)=f(g(x))$ is periodic where $g(x)=x$(non periodic) and $f(x)=\sin(x)$.
Can the above condition be made into a necessary and sufficient condition (assuming that $g(x)$ is not the identity function) or is there a better way to find the solution?
This is from a previous year college entrance exam. Any short trick rather to check for the periodicity of $f(g(x))$ when $g(x)$ is a complicated function would be helpful.