[求助]看看我写的这个程序哪里有错啊
/*求方程f(x)=x3+1.1x2+0.9x-1.4=0在[0,1]区间内的实根近似解,使得误差不超过0.0001*/using System;
namespace FcApp
{
class Class1
{
static void Main(string[] args)
{
double y;
double x=0.0001;
int n=100;
int i=0;
double [] s=new double [n];
do
{
i++;
y=x*x*x+1.1*x*x+0.9*x-1.4;
if(y==0)
{
if(x<=1&&x>=0)
s[i]=x;
}
Console.WriteLine ("s[n]={0}",s[i]);
}
while (x>0.0001);
}
}
}