Q. Write a C program to print the following star-hash pyramid design:
#####*#####
####*#*####
###*###*###
##*#####*##
#*#######*#
*#########*
/**************************************************************
So you can see, there are four types pyramid in above design as:
##### * #####
#### *# * ####
### *## #* ###
## *### ##* ##
# *#### ###* #
*##### ####*
Hence, now it is easy to make these above pyramid program. So i recommended to make first above four pyramid program, after making these pyramid design, add these all pyramid in single C program and you are done. :) )
**************************************************************/
Ans.
/*c program for nested star-hash pyramid*/
#include<stdio.h>
int main()
{
#####*#####
####*#*####
###*###*###
##*#####*##
#*#######*#
*#########*
/**************************************************************
How To Make Above nested Pyramid C program
***************************************************************So you can see, there are four types pyramid in above design as:
##### * #####
#### *# * ####
### *## #* ###
## *### ##* ##
# *#### ###* #
*##### ####*
Hence, now it is easy to make these above pyramid program. So i recommended to make first above four pyramid program, after making these pyramid design, add these all pyramid in single C program and you are done. :) )
**************************************************************/
Ans.
/*c program for nested star-hash pyramid*/
#include<stdio.h>
int main()
{