Suppose that is continuous and on and
Prove has no minimum on
Prove has a maximum on (note that is not compact).
Prove under weaker hypothesis than positivity on all of .
For (c) we're going to assume for some . Take an interval of the form and take the maximum of f there say (if it's zero we'll deal with it later). Now since when we have two constants such that whenever or take and so we have that attains a maximum in with and since out of this interval the function never exceeds , is a global maximum.
If were and in I we're finished. If it's on an unbounded interval apply a similar argument to the above, if on a bounded interval it's clear it has a maximum. And this covers all cases.