标签:金字塔 while i++ nbsp turn bsp printf ++ print
#include <stdio.h> int main() { int i,j,k,n; while(scanf("%d", &n)!=EOF){ for(i=1;i<=n;i++) { for(j=1;j<=n-i;j++) printf(" "); for(k=1;k<2*i;k++) printf("*"); printf("\n"); } } return 0; }
标签:金字塔 while i++ nbsp turn bsp printf ++ print
原文地址:https://www.cnblogs.com/Estwind/p/10100001.html