Two examples are given below, but many are possible.

If f(x)=ex, then f(x)>0 for all x. As we move left along the x-axis, f(x) gets smaller and smaller, approaching 0 but never reaching it. Since f(x) gets smaller and smaller as we move left, there is no global minimum. Likewise, f(x) increases more and more as we move right, so there is no maximum.

If f(x)=arctan(x)+2, then f(x)>(−2π)+2>0 for all x.
As we move left along the x-axis, f(x) gets smaller and smaller, approaching (−2π+2) but never reaching it. Since f(x) gets smaller and smaller as we move left, there is no global minimum.
Likewise, as we move right along the x-axis,
f(x) gets bigger and bigger, approaching (2π+2) but never reaching it. Since f(x) gets bigger and bigger as we move right, there is no global maximum.