i want to put the answer like user enter any odd number then out put will be like this one if 3

***

* *

***

the even rows shows only 1st and last stars LIKE 5

*****

* *

*****

* *

*****

```
int main(){
int num,i,j,k,l;
printf("press any odd num");
scanf("%d",&num);
if(num%2==0){
printf("use odd number thanks");
}
for(i=1;i<=num;i++){
for(j=i;j<=i;j++)
if(j==1&&j==num){
printf("*");
}
else
printf(" ");
getch():
return 0;
}
}
```