为什么会没有输出?
#include<stdio.h>#include<conio.h>
void linee(float x1,float y1,float x2,float y2){
float x1;float y1;
float x2;float y2;
float a,x,y;
a=x1;
for(a;a<=x2;a+=0.1)
{x=a;
y=((y1-y2)/(x1-x2))*(x-x1)+y1;
gotoxy(x,y);
printf("*");
}
}
int main(){
float x1,y1,x2,y2;
printf("输入初始坐标。");
scanf("%f",&x1);
scanf("%f",&y1);
printf("输入末坐标。");
scanf("%f",&x2);
scanf("%f",&y2);
linee(x1,y1,x2,y2);
return 0;}