/*班級:一毅 座號:37號 姓名:趙翊伶*/
/*程式功能:*/
/*日期:101/03/28*/
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
FILE *in;
int main()
{
int n,a,b,c,i;
double x1,x2,D;
in=fopen("in.txt", "r");
fscanf(in,"%d",&n);
for(i=1;i<=n;i++)
{
fscanf(in,"%d %d %d",&a, &b, &c);
D=pow(b,2)-4*a*c;
x1=(-b+sqrt(D))/(2*a);
x2=(-b-sqrt(D))/(2*a);
printf("兩根解為:%.3lf或%.3lf\n",x1,x2);
}
fclose(in);
system("PAUSE");
return 0;
}