标签:do..while
// 用do...while语句求1+2+3+...+100. #include <stdio.h> int main() { int i = 1; int sum = 0; do { sum = sum + i; i++; }while(i <= 100); printf("1+2+...+100 = %d\n",sum); return 0; }
【c语言】用do...while语句求1+2+3+...+100
标签:do..while
原文地址:http://blog.csdn.net/zhaoyaqian552/article/details/45247077