The problem with the quadratic formula as stated is that the expression 2 * a needs to be expressed as (2 * a). Without the parentheses the expression will be evaluated incorrectly as (-b + sqrt(b * b - 4 * a * c)) / 2 multiplied by a.