Show that if two maximal values are equal on continuous functions, then there exists $\psi \in [a,b]$ with $f(\psi) = g(\psi)$ Let $f,g : [a,b] \rightarrow \mathbb{R}$ be continuous. We know that $f$ and $g$ have maximal values, as they are continuous on a closed interval. Let $M_f$ be the maximal value of $f$, and $M_g$ the maximal value of $g$. Show that if $M_f$ = $M_g$, then there exists $\psi \in [a,b]$ with $f(\psi) = g(\psi)$
Would it suffice to show that $\psi$ = maximal values, and show that this is an example which shows the exist of such a $\psi$?

Suppose that $f(x_1) = M_f$ and $g(x_2) = M_g$ and assume without loss of generality that $x_1 < x_2$. Now consider $h:=f-g$ restricted to the interval $[x_1,x_2]$. Note that
$$
h(x_1) = f(x_1) - g(x_1) = M_g - g(x_1) \geq 0
$$
and
$$
h(x_2) = f(x_2) - M_f \leq 0
$$
So if $h(x_1) = 0$ or $h(x_2) = 0$ we are done. Else, the intermediate value theorem applies.
