#includevoid main(){ int i=1,sum_i=0; while((sum_i+=i)<1000) i++; printf("i=%d sum_i=%d",i,sum_i);}结果:i=45 sum_i=1035Press any key to continue