According to $[2]$ we have:
$\textbf{Definition 9. 6. 5 (Maxima and minima).}$ Let $f: X\to \mathbf{R}$ be a function, and let $x_0\in X$. We say that $f$ attains its maximum at $x_0$ if we have $f(x_0)\geq f(x)$ for all $x\in X$ (i.e., the value of $f$ at the point $x_0$ is larger than or equal to the value of $f$ at any other point in $X).$ We say that $f$ attainsits minimum at $x_0$ if we have $f(x_0)\leq f(x).$
$\textbf{Proposition 9. 6. 7}$(Maximum principle). Let $a< b$ be real numbers, and let $f: [ a, b] \to \mathbf{R}$$be$$a$ function continuous on $[ a, b] .$ Then $f$ attains its maximum at some point $x_{max}\in [ a, b]$ ,and also attains its minimum $at$ some point $x_{min}\in [ a, b] .$
And according to $[1]$:
Definition $\mathbf{10.18}$. A function $f:[a,b]\to\mathbf{R}$ is piecewise continuous if there exist real numbers $\alpha=x_0<x_1<\cdots<x_k=b$ such that $f$ is continuous in the interval $(x_j-1,x_j)$, for $1\leq j\leq k$, and the lateral $\lim_{x\to a+}f(x),\lim_{x\to b-}f(x)$$\operatorname{and}\lim_{x\to x_j\pm}f(x)$ exist, for $1\leq j<k.$
If $f:[a,b] \subset \mathbf{R} \to \mathbf{R}$ is piecewise continuous, then there exists $M>0$ such that $|f(x)| \leq M$ for all $x \in [a,b]$ or equivalently the Maximum Principle is true of piecewise continuous? So:
Question. The Maximum Principle is true for piecewise continuous?
$[1]$ Muniz Neto, A. An Excursion through Elementary Mathematics, Volume I. Springer, 2017.
$[2]$ Tao, T. Analysis I. Third Edition, Springer Singapore, $2016$.