Max and Min continuous in general topology Let $(X,\mathcal{T})$ be a topological space. Futhermore $f$ and $g$ are continuous functions mapping to $\mathbb R$. 
Is it true that $\text{min}(f,g): X\to \mathbb{R}$ is continuous?
 A: Hint: $\min(a,b)=\dfrac{1}{2}(a+b-|a-b|)$
Edit: fixed formula for min
A: I think yes that is true. Take this function $h(x)= \frac{f(x)+g(x)}{2}-\frac{|f(x)-g(x)|}{2}$. So if f(x)>g(x), then h(x)=min(f(x),g(x))=g(x) and vice versa for g(x)>f(x). So h is continuous as sum of two continuous function and modulus of continuous function is continuous. 
A: Hint. Consider the mapping $F \colon X \to \mathbb{R} \times \mathbb{R}$ defined by $F(x) = (f(x),g(x))$ and compose it with the mapping $\min \colon \mathbb{R} \times \mathbb{R} \to \mathbb{R}$ defined in the obvious way. Thus it is enough to prove that the function $\min$ is continuous.
A: This is true when $f$ and $g$ take values in any ordered topological space $(Y, <)$, in fact. Let $h(x) = \min(f(x), g(x))$. For all $y \in Y$: 
$$x \in h^{-1}[(\leftarrow, y)] \leftrightarrow h(x) < y \leftrightarrow (f(x) < y \lor g(x) < y) \leftrightarrow x \in f^{-1}[(\leftarrow, y)] \cup g^{-1}[(\leftarrow, y)]\text{,}$$
and 
$$x \in h^{-1}[(y, \rightarrow)] \leftrightarrow h(x) > y \leftrightarrow (f(x) > y \land g(x) > y) \leftrightarrow x \in f^{-1}[(y, \rightarrow)] \cap g^{-1}[(y, \rightarrow)]\text{.}$$
Which shows that the inverse images of $h$ of subbasic elements are open (when $f$ and $g$ are continuous), and so $h$ is continuous. It also quite easily shows the same for the $\max$ function (we only need to interchange the lines, sort of). 
