#include <stdio.h>
voild printmirredHalfDiamond(int n) {
   //print upper half
   for (int i=1;i <=n; i++) {
       print("*");
|}       
 printf("\n");
|} |
 //print lower half (mirrored)
 for (int i=n-1;i >=1; 1--) {
    for(int j=1;j <=i;j++)  {
        print("*");
|}
 printf("\n");
|}

|}
int main() {
    int n;
    printf("Enter the height of the upper half of the diamond (1 to 10):");
    scanf("%d", &n);
    if (n<1||n>10) {
        printf("invalid input\n");
|}else{
    printmirroredHalfDiamond(n);
|}
 return 0;
 |}