$\displaystyle f$ is a continous function at $\displaystyle R$ which gets a local maximum at point $\displaystyle x{}_{0}$. i need to prove - formal proof, not just words - that if $\displaystyle f$ doens't have any other extremas, $\displaystyle f$ getsmaximum at $\displaystyle x{}_{0}$

for clarification of how us in the course define extrema: "$\displaystyle f(x)$ is an extrema value if $\displaystyle f(x)$ is a local minimum or a local maximum of $\displaystyle f$. in this case we'd say that the point $\displaystyle (x,f(x)) $ on $\displaystyle f$'s graph is called an extrema of $\displaystyle f$"