Now I understand that the function space $\mathcal{C}[a,b]$ of continuous functions from the closed interval $[a,b]$ to $\mathbb{R}$ is complete, with the metric:
$ d(x, y) = \underset{t \ \in \ [a,b]}{\max} \vert x(t) - y(t) \vert $
I also understand the theorem which states that a subspace $M$ of a complete metric space $X$ is itself complete if and only if the set $M$ is closed in $X$.
Finally I understand that $M$ is closed if and only if the situation $x_n \in M, x_n \longrightarrow x$ implies that $x \in M$.
What is don't know what to do is how to put this all together to show that the given subspace $Y$ is closed in $\mathcal{C}[a,b]$.
Let $(x_n)_{n \in \mathbb{N}}$ be a sequence in Y. Suppose that $x_n \rightarrow x.$ We want to prove that $x \in Y$.
For all $\varepsilon>0$, there exists $n_0$ such that $n\geq n_0 \Rightarrow d(x_n,x)< \varepsilon/2$
Since $x_{n_0}(a)=x_{n_0}(b)$, we have: $$|x(a)-x(b)| \leq |x(a)-x_{n_0}(a)|+|x_{n_0}(a)-x_{n_0}(b)|+|x_{n_0}(b)-x(b)| $$ $$=|x(a)-x_{n_0}(a)|+ |x_{n_0}(b)-x(b)| \leq 2d(x_{n_0},x)< \varepsilon $$
Then $|x(a)-x(b)| < \varepsilon$, $\forall \varepsilon>0 \Rightarrow |x(a)-x(b)| = 0 \Rightarrow x(a)=x(b) \Rightarrow x \in Y.$
Thus $Y$ is closed.