Let $f:\mathbb{R}\times [0,1]\to\mathbb{R}$ be a continuous function and $\{x_n\}$ a sequence of real numbers converging to $x$. Define
$g_n(y)=f(x_n,y)$, $0\leq y\leq1$,
$g(y)=f(x,y)$, $0\leq y\leq1$.
Show that $g_n$ converges to $g$ uniformly on $[0,1]$.
I don't need a complete solution, but a bit of direction would be extremely useful. Thank you!
Let $\epsilon>0$ be given.
Now, $\left|g_n(y)-g(y)\right|=\left|f(x_n,y)-f(x,y)\right|$
As $f$ is continuous, therefore for each $y\in\left[0,1\right]$, $\exists N_{\epsilon,y}\in\mathbb{N}$ such that $\left|f(x_n,y)-f(x,y)\right|<\epsilon$ whenever $n\geq N_{\epsilon,y}$.
Now, $\left[0,1\right]=\bigcup_{y\in\left[0,1\right]}(y-\epsilon,y+\epsilon)$. As $\left[0,1\right]$ is compact, there exists a finite subcover. Thus, there exists $m\in\mathbb{N}$ such that $\left[0,1\right]=\bigcup\limits_{i=1}^{m}(y_i-\epsilon,y_i+\epsilon)$. Now any $y\in\left[0,1\right]$ belongs to one of the intervals $(y_i-\epsilon,y_i+\epsilon)$ for some $i$. Thus, taking $N=$ max$\{N_{\epsilon,y_i}: i=1,2,...,m\}$, we get that $g_n$ converges to $g$ uniformly on $\left[0,1\right]$.