fork download
  1. #include<stdio.h>
  2. #include<math.h>
  3. int main()
  4. {
  5. double x,q,c;
  6. while(1){
  7. scanf("%lf",&q);
  8. if(q==-1)break;
  9. x=q/2;
  10. while(fabs(x*x*x-q)>0.0000001*q){
  11. c=x-(x*x*x-q)/(3*x*x);
  12. x=c;
  13. }
  14. printf("%lf\n",x);
  15. }
  16. return 0;
  17. }
Runtime error #stdin #stdout 0.18s 159232KB
stdin
189377
stdout
./prog.factor

1: #include<stdio.h>
                    ^
No word named “#include<stdio.h>” found in current vocabulary search path