作者ahongyeh (小叶子)
看板TransCSI
标题Re: [问题] 一题小考题目
时间Tue Oct 31 14:12:54 2006
#include<stdio.h>
main(){
int n,i,j;
printf("Please input the size of side of square (1~20) : ");
scanf("%d",&n);
for(i=1;i<=n;i++){
for(j=1;j<=n;j++)
printf("*");
printf("\n");
}
}
※ 引述《myemail (频可欣)》之铭言:
: write a program that reads in the side of a square and prints that
: square out of asterisks. Your program should work for squares of
: all sides between 1 and 20. For example, if your program reads a
: side of 4, it should print
: ****
: ****
: ****
: ****
: 这是我小考题目,请各位大大帮我解答一下 谢谢^^
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 219.68.184.163