浮点数如何原样输出(小数位数不变)
#include <stdio.h>int main()
{
float x, y=0;
printf("Enter a number: ");
scanf("%f", &x);
do
{
if (x > y)
x = x;
else
x = y;
printf("Enter a number: ");
scanf("%f", &y);
}while (y > 0);
printf("The largest number entered was %f\n", x);
return 0;
}
原程序~~~求解