title: How to make word triangle in c++ with for loop
body: <p>how can I make this type of triangle:
  where the size of triangle n = 5;</p>
  
  <pre><code>Five Four Three Two One
  Five Four Three Two
  Five Four Three
  Five Four
  Five
  </code></pre>
  
  <p>Here's what I've tried:</p>
  
  <pre><code>int n;
  cout&lt;&lt;"Enter Size of triangle: ";
  cin&gt;&gt;n;
  
  for(int i = n; i &gt;= 1; i--){
      for(int j = n; j &gt;= i; j--){
          cout&lt;&lt;j&lt;&lt;" ";
      }
      cout&lt;&lt;endl;
  }
  </code></pre>