=============================================================
Explanation:
The y coordinates are identical, so we just need to focus on the x coordinates.
Going from 0 to -3 is a distance of 3 units. Drawing out a number line might help.
Or we could apply subtraction and absolute value
|x1-x2| = |0-(-3)| = |0+3| = |3| = 3
which is the same as
|x2-x1| = |-3-0| = |-3| = 3
The absolute value is to ensure the result is never negative. Distance is never negative.
Side note: if the y coordinates weren't the same, then we'd have to use either the pythagorean theorem or the distance formula.