#include <档岩漏stdio.h>double 枣郑f(double x){ return x*x*x-x*x-2*x+1;}int main(void) { double low=0,up=1; for(;up-low>=1e-3;) { if(f((up+low)/2)<0) up=(up+low)/2; else low=(up+low)/2; } printf("%.3lf\n"行烂,(up+low)/2); return 0;}