**My attempt**

Let $X=\{x \in [a,b]; f|[a,x]$ is bounded $\}$. 

We have $a\in X$ and $X \subset [a,b] \Rightarrow$ $X$ is non-empty and bounded. 

Therefore
there exists $c = \sup X \leq b$.

We have:

**1)** $c \in X$;

Indeed, take $\varepsilon = 1$, since $f$ is continuous at $c$, there
exists $\delta>0$ such that
$x \in (c-\delta, c + \delta) \cap [a,b] \Rightarrow |f(x)-f(c)| < 1$.

Since $c-\delta<c$, there exists $y\in X$ such that $c-\delta<y\leq c$. Since $y \in X$ we have $f|[a,y]$ bounded.

$f|(y,c]$ is also bounded:
Let $x\in (y,c] \subset (c-\delta, c + \delta).$
Then $|f(x)| \leq |f(x)-f(c)| + |f(c)| < |f(c)| + 1$.
Therefore $f|(y,c]$ is bounded. 

Thus $f|[a,c]$ is bounded $\Rightarrow c \in X$.

**2)** $c=b$;

By contradiction, let's suppose that $c<b$.

Take $\varepsilon = 1$, since $f$ is continuous at $c$, there
exists $\delta>0$ such that
$x \in (c-\delta, c + \delta) \cap [a,b] \Rightarrow |f(x)-f(c)| < 1$.

Let $y \in (c, \min \{ c + \delta, b\})$. We have $y\in [a,b]$. 

$f|[a,c]$ is bounded since $c \in X$. 

$f|(c,y]$ is also bounded: 

Let $x \in (c, y] \subset (c-\delta, c + \delta)
\cap [a,b]$.
Then $|f(x)| \leq |f(x)-f(c)| + |f(c)| < |f(c)| + 1 $. Therefore
$f|(c,y]$ is bounded.

Thus $f|[a,y]$ is bounded$ \Rightarrow y\in X$. We have $y>c = \sup X$, which is a contradiction, 

Then $c=b$.

**3)** $X=[a,b]$.

Indeed, let $x \in [a,b]$. So $f([a,x]) \subset f([a,b])$. Since
 $f([a,b])$ is bounded we have $f|[a,b]$ bounded $\Rightarrow x \in X$.

Thus, $X=[a,b]$.

Am I right?