I now see the importance of f. Since g(n)≠n, g(n) = p for some 1≤p≤n-1. Similarly, h(n) = q for some 1≤q≤n-1. Since we have freedom to choose f, we can define it such that f(p) = q. Now, if f' is the identity (I still don't see its importance), then h(n) = (f°g°f')(n). Similarly, we can define...