2008. 12. 30. 23:11
C/C++/MFC
하드 코딩 ㅡㅡV
#include<stdio.h>
main()
{
int num, over, star;
for(over=1; over<=3; over++){
for(num=9;num>=over; num--){
printf(" ");
}
for(star=1; star<=over*2-1; star++){
printf("*");
}
printf("\n");
}
for(over=0; over<=2; over++){
for(star=19; star>=over*2; star--){
printf("*");
}
printf("\n");
for(num=0; num<=over; num++){
printf(" ");
}
}
for(over=3; over>=1; over--){
for(star=19; star>over*2; star--){
printf("*");
}
printf("\n");
for(num=2; num<=over; num++){
printf(" ");
}
}
for(over=3; over>=1; over--){
for(num=9;num>=over; num--){
printf(" ");
}
for(star=1; star<=over*2-1; star++){
printf("*");
}
printf("\n");
}
}