G5.2 Let $b$ be the maximum of the function $y=\left|x^{2}-4\right|-6 x$ (where $-2 \leq x \leq 5$ ), find the value of $b$.
When $-2 \leq x \leq 2, y=4-x^{2}-6 x=-(x+3)^{2}+13$
Maximum value occurs at $x=-2, y=-(-2+3)^{2}+13=12$
When $2 \leq x \leq 5, y=x^{2}-4-6 x=(x-3)^{2}-13$
Maximum value occurs at $x=5, y=-9$
Combing the two cases, $b=12$