I am struggling solving the following exercise:
Let $a \in \mathbb{R}^n$ and $ b \in \mathbb{R}$ and define $f : \mathbb{R}^n \rightarrow \mathbb{R}$ by
$f (x)=\langle x,a \rangle + b, x\in \mathbb{R}^n$
Show that for every convex set $X$ in $\mathbb{R}^n$, $ f (X) =\{ f(x):x \in X \} $ is a convex set in $\mathbb{R}$.
Thank you!