title: I am new to python programming and I have an assignment in which I have to print a certain pattern of stars using a function
body: <p>The pattern is given below. The number of rows is to be specified by the user. In this image it is 6. I know how to print the upper half but I am finding difficulty in the lower half. Please help.</p>
  
  <p><a href="https://i.stack.imgur.com/o9wFp.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/o9wFp.png" alt="enter image description here"></a>
  I tried this code:</p>
  
  <pre><code>def asterisk_triangle(n):
  x = 1
  while (x &lt;= n):
      print("*" * x)
      x = x + 1
  return
  </code></pre>