title: Creating an hourglass using asterisks
body: <p>I would like to create an hourglass using the "*" character. For example if the user input was 5 then it would look like this:</p>
  
  <pre><code>*****
   ***
    *
   ***
  *****
  </code></pre>
  
  <p>and 3 would look like this:</p>
  
  <pre><code> ***
    *
   ***
  </code></pre>
  
  <p>So far I have:</p>
  
  <pre class="lang-java prettyprint-override"><code>public static void draw(int W){
      stars(W);
      if (W &gt; 1) {
          draw(W-1);
          stars(W);
      }
  }
  public static void stars(int n){
      System.out.print("*");
      if(n&gt;1) stars(n-1);
      else System.out.println();
  }
  </code></pre>
  
  <p>and it creates</p>
  
  <pre><code> *****
   ****
   ***
   **
   *
   **
   ***
   ****
  </code></pre>
  
  <hr>