#include<stdio.h>
int main(){
    int n;
    printf("enter the height of the upper half of the diamond(1-10)");
    scanf("%d",$n);
    if(n<1 || n>10){
        printf("Invalid input\n");
        return 0;
    }
    for(int i=1;i<=n;i++){
        for(int j=1;j<=i;j++){
        printf("*");
    }
    printf("\n");
}
for(int i=n-1;i>=1;i--){
    for(int j=1;j<=i;j++){
        printf("*");
    }
    printf("\n");
}
return 0;
}