hello im new in programming and i need help in printing this kind of output

*
    * *
  *  *  *
*  *   *  *

the number of iterations depends on users input please help me

That's not a typical pyramid pattern for beginners. Can you provide a larger example? 10 rows, perhaps?

Watch the pattern carefully and think a bit.
First can you code for the pattern:-
*
**
***
****

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.