Absolute value proof, $|a|\leq\max\{|x|,|y|\}$

47 Views Asked by At

I would like to confirm a proof I made:

For every $a,x,y \in\mathbb{R}$ such that $x≤a≤y$, we have $|a|≤\max\{|x|,|y|\}$.

I assumed that $|x|≤|y|$, so: $-|y|≤a≤|y|$, and that means: $a≤|y|$. Then, I assumed: $|y|≤|x|$, so $-|x|≤a≤|x|$, and that means: $a≤|x|$

From here, I let $b\in\mathbb R$, such that $b=\max\{|x|,|y|\}$ and that means $a≤b$.

From here I don't really know what to do or if all I did is true or not.

Thank you for your help!