---
title: "How to print pattern like this"  
description: "How to print pattern like this"  
author: "Manoj Bhatt"  
published: 2013-06-14  
updated: 2013-06-15  
canonical: https://www.mindstick.com/forum/1112/how-to-print-pattern-like-this  
category: "visual c++"  
tags: ["visual c++"]  
reading_time: 1 minute  

---

# How to print pattern like this

Hi,\
How to [print](https://www.mindstick.com/blog/301752/types-of-3d-printing-technology) [pattern](https://www.mindstick.com/forum/2314/what-is-the-mvp-and-mvc-pattern) like this using [C++](https://www.mindstick.com/blog/745/array-in-c-plus-plus)?\
* * * * * * * * * * * *\
Thanks in advance.\

## Replies

### Reply by AVADHESH PATEL

Hi, \
Try this:\

```
int main( ){ int i,j;  for(i==0;i<5;i++)  {    for (j=5;j>0;j--)    {      if( j<=i )        {          cout<<"*";          cout<<" ";         }      else      {        cout<<" ";        cout<<" ";       }     }  cout<<"\n";  }}
```


---

Original Source: https://www.mindstick.com/forum/1112/how-to-print-pattern-like-this

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
