title: There is a small glitch in my second if/else statement, I think, can you help me find it?
body: <p>There is a small glitch in my second if/else statement, I think, can you help me find it?
  The once word == 1 the value of word is supposed to change to "bottle" but it is printing "bottles."</p>
  
  <hr>
  
  <pre><code>public class milkSong
  {
      public static void main(String[] args) {
          int milkNum = 10; //decreased the bottles of milk so that the output would fit
          String word = "bottles";
  
          while (milkNum &gt; 0) {
  
              if (milkNum == 1) { 
                  word = "bottle"; 
              }
  
              System.out.println (milkNum + " " + word + " of milk on the wall.");
              System.out.println (milkNum + " " + word + " of milk.");
              System.out.println ("Take one down.");
              System.out.println ("Pass it around.");
              milkNum = milkNum - 1;
  
             //There is a problem with this statement, once beerNum == 1, still printing "bottles"
              if (milkNum &gt; 0) { 
                  System.out.println (milkNum + " " + word + " of milk on the wall.");
              } 
              else {
                  System.out.println ("No more bottles of milk on the wall.");
              }
  
          }
  
      }
  }
  </code></pre>