since you're using `float` arguments, you really want to use `fabsf()` instead of `abs()`.