一个解方程的程序
可是不能输出正确的结果:#include<stdio.h>
void main()
{
int x,y;
printf("please input x\n");
scanf("%d",&x);
if(x<1)
{
y=x;
printf("x=%d,y=x=%d\n");
}
else if(x<10)
{
y=2*x-1;
printf("x=%d,y=2*x-1=%d\n");
}
else
{
y=3*x-11;
printf("x=%d,y=3*x-11=%d\n");
}
}