#include<stdio.h>
#include<conio.h>
void main()
{
int
i,n,j;
scanf("%d",&n);
printf("\n\n");
for(i=0;i<n+n/2-1;i++)
{
for(j=0;j<n+n/2-1;j++)
{
if((i==0&&j<=n-1)||(j==0&&i<=n-1)||(i==n-1&&j<=n-1)||(j==n-1&&i<=n-1)||(i>=n/2&&i==j))
{
printf("*");
}
else
{
printf(" ");
}
}
printf("\n");
}
}
No comments:
Post a Comment