Suppose $f(x_1,x_2,...,x_n)$ is an affine function, $\mathbb{R}^n\rightarrow\mathbb{R}^m$. Let $$ g(x_1,x_2,...x_n) = \max\{f(x_1,x_2,...,x_n)\} - \min\{f(x_1,x_2,...,x_n)\} $$ The max and min functions find the m-dimensional component's corresponding maximum/minimum value. The question is whether $g(x_1,x_2,...x_n)$ is a convex function.
I taught myself some simple knowledge of convex optimization, including convex sets, convex functions, convex preserving properties, etc. I'd appreciate it if you could answer this question with what I know. Thank you for your time!