Wednesday, October 7, 2020

C Mirrored Rhombus Star Pattern

 



CODE :-

#include<stdio.h>
int main()
{
int i, j, k, num, n;
printf("\nEnter a number: ");
scanf("%d",&num);
printf("\n");
n = num;
for(i = 0; i < num; i++)
{
for(k = 0; k < i+1; k++)
{
printf(" ");
}
for(j = 0; j < num; j++)
{
printf("*");
}
printf("\n");
}
return 0;
}

    Choose :
  • OR
  • To comment
No comments:
Write Comments