/* This is a main routine that will call your function newton * to find the roots of an equation */ #include #include double newton(double guess, double tolerance); int main(int argc, char * argv[]) { double f; double guess,tolerance; if(argc < 3 ){ printf("Usage: %s initial_guess tolerance\n",argv[0]); return 1; } guess = strtod(argv[1],NULL); tolerance = strtod(argv[2],NULL); f = newton(guess,tolerance); printf("This is the answer: %lf using %lf as an initial guess.\n",f,guess); } // Below is the function to edit. double newton(double guess, double tolerance) { double value; return value; }