Bisection method for finding the root of a function
It is customary to use eps instead of e.
A ((b-c) / c) &lt;=e condition doesn't look right (try \$f(x) = x\$ on the \$(-1, 1)\$ interval and observe a division by 0).
You seem to assume that b &gt; a (otherwise the loop breaks immediately). Make sure to swap a and b if it is not so. Making sure that eps is positive also helps.
The code produces wrong results for a non-continuous \$f\$. I recommend to test that the function value at a suspected root is close enough to \$0\$.
Avoid break. while (b - a &gt; eps) is much cleaner.