求助一个while问题?
#include <stdio.h>main ()
{
float a, b_b, t_c1, t_c2, c_l, b;
while (a != 0)
{
printf ("enter account number:");
scanf ("%f",&a);
printf ("enter beginning balance :");
scanf ("%f", &b_b);
printf ("enter total charge :");
scanf ("%f", &t_c1);
printf ("enter total credits :");
scanf ("%f", &t_c2);
printf ("enter credit limit :");
scanf ("%f", &c_l);
b=b_b + t_c2 ;
if (b>c_l)
{
printf ("Account :%f\n",a);
printf ("Credit limit :%.2f\n", c_l);
printf ("Balance :%.2f\n", b);
printf ("Credit limit Exceeded\n");
}
}
}
现在是输入 a=0 还会继续一轮操作才会停止,
怎样使a=0时直接不继续?