Question about continuity function Show that $f:A$ to $R$ is continuous on $A⊆R$ and if $n∈N$, then the function $f^n$ defined by $f^n (x)=(f(x))^n$, for $x∈A$, is continuous on A.
Can anyone help me with this problem, thank you!
 A: Here is a proof that does not use induction on the product of continuous functions.
Note that
$$|f(y)^n-f(x)^n|=\left|(f(y)-f(x))\sum_{j=1}^{n}f(y)^{n-j}f(x)^{j-1}\right|\leq|f(y)-f(x)|\sum_{j=1}^{n}|f(y)^{n-j}f(x)^{j-1}|.$$
If $|f(y)-f(x)| < 1$, then 
$$|f(y)|-|f(x)|\leq||f(y)|-|f(x)|| \leq |f(y)-f(x)|<1,$$
and $|f(y)| < 1 + |f(x)|$. This implies $|f(y)^{n-j}f(x)^{j-1}|<(1+|f(x)|)^{n-1}.$
Then
$$|f(y)^n-f(x)^n| \leq n|f(y)-f(x)|[1 + |f(x)|^{n-1}].$$
Fix $x$. By the continuity of $f$, for any $\epsilon > 0$ there exists $\delta > 0$ such that if $|y-x| < \delta$ then,
$$|f(y) - f(x)| < \min\left(1,\frac{\epsilon}{n[1 + |f(x)|^{n-1}]}\right),$$
and
$$|f(y)^n-f(x)^n| < \epsilon.$$
A: Let $n\in{\mathbb N}$ be given. We begin by proving that the function
$$p:\quad{\mathbb R}\to{\mathbb R},\qquad y\mapsto y^n$$
is continuous, which is the same as continuous at every point $a\in{\mathbb R}$.
Let an $a\in{\mathbb R}$ be given. When discussing $|p(y)-p(a)|$ for $y$ near $a$ it suffices to consider points $y$ with $|y|\leq|a|+1$ to begin with. One then has
$$p(y)-p(a)=(y-a)\bigl(y^{n-1}+y^{n-2}a+\ldots+a^{n-1}\bigr)$$
and therefore
$$|p(y)-p(a)|\leq |y-a| \ n \bigl(|a|+1)^{n-1}\ .$$
This says that
$$|p(y)-p(a)|\leq M\ |y-a|\qquad\bigl(|y|\leq|a|+1\bigr),$$
where $M$ does not depend on $y$, and proves the continuity of $p$ at $a$.
Now the function $g(x):=\bigl(f(x)\bigr)^n$ can be written as $g=p\circ f$, and this proves the continuity of $g$.
