题目内容

以下程序的运行结果是 。#include main(){int i=1,s=3;do{s+=i++;if (s%7==0)continue;else++i;} while (s<15);printf("%d\n",i);}

查看答案
更多问题

以下程序的运行结果是____。#include main(){int i,j;for (i=4;i>=1;i--){printf("*");for (j=1;j<=4-i;j++)printf("*");printf("\n");}}

以下程序的运行结果是____。#include main(){int i,j,k;for (i=1;i<=6;i++){for (j=1;j<=20-2*i;j++)printf(" ");for (k=1;k<=i;k++)printf("%4d",i);printf("\n");}}

以下程序的运行结果是____。#include main(){int i,j,k;for (i=1;i<=6;i++){for (j=1;j<=20-3*i;j++)printf(" ");for (k=1;k<=i;k++)printf("%3d",k);for (k=i-1;k>0;k--)printf("%3d",k);printf("\n");}}

以下程序的运行结果是____。#include main(){int i,j,k;for (i=1;i<=4;i++){for (j=1;j<=20-3*i;j++)printf(" ");for (k=1;k<=2*i-1;k++)printf("%3s","*");printf("\n");}for (i=3;i>0;i--){for (j=1;j<=20-3*i;j++)printf(" ");for (k=1;k<=2*i-1;k++)printf("%3s","*");printf("\n");}}

答案查题题库