The hypothesis that
$\displaystyle \lim_{x \to \infty} f(x) \in \Bbb R \tag 1$
means that
$\exists L_+ \in \Bbb R, \; \displaystyle \lim_{x \to \infty} f(x) = L_+; \tag 2$
that is,
$\forall 0 < \epsilon_+ \in \Bbb R \; \exists 0 < M_+ \in \Bbb R, \; x > M_+ \Longrightarrow \vert f(x) - L_+ \vert < \epsilon_+; \tag 3$
that is,
$x > M_+ \Longrightarrow L_+ - \epsilon_+ < f(x) < L_+ + \epsilon_+; \tag 4$
likewise the hypothesis
$\displaystyle \lim_{x \to -\infty} f(x) \in \Bbb R \tag 5$
gives us
$\exists L_- \in \Bbb R, \; \displaystyle \lim_{x \to -\infty} f(x) = L_-; \tag 6$
i.e.,
$\forall 0 < \epsilon_- \in \Bbb R \; \exists 0 > M_- \in \Bbb R, \; x < M_- \Longrightarrow \vert f(x) - L_- \vert < \epsilon_-, \tag 7$
or
$x < M_- \Longrightarrow L_- - \epsilon_- < f(x) < L_- + \epsilon_-; \tag 8$
it follows that, letting
$b = \min(L_- - \epsilon_-, L_+ -\epsilon_+), \; B = \max(L_- + \epsilon_-, L_+ + \epsilon_+) \tag 9$
and
$m = \max(-M_-, M_+), \tag{10}$
that
$\vert x \vert > m \Longrightarrow b < f(x) < B, \tag{11}$
so $f(x)$ is bounded on the set $(-\infty, m) \cup (m, \infty)$; furthermore, since the closed interval $[-m, m]$ is compact and $f(x)$ is continuous, $\vert f(x) \vert$ is strictly bounded on this interval by some $0 < \beta \in \Bbb R$:
$x \in [-m, m] \Longrightarrow -\beta < f(x) < \beta; \tag{12}$
combining (11) and (12) shows that $f(x)$ is bounded on all of $\Bbb R$. Indeed, we have
$\forall x \in \Bbb R, \; \vert f(x) \vert < \max(\vert b \vert, \vert B \vert, \beta). \tag{13}$