def newton_find_root(func, fprime, x0, num_iterations=10, full_output=True):
"""
Use Newton's method to find a root of ``func`` with initial guess x0
where ``func`` is a differentiable function in one variable with derivative ``fprime``.
"""
x0 = float(x0)
for i in range (num_iterations):
x0 = x0 - func(x0)/fprime(x0)
if full_output == True:
print float(x0)
return x0