title: Missing return statement for if/else statement
body: <pre><code>public int checkGuess(int g, int randomnumber){
  
      number=g;
      this.randomnumber= randomnumber;
  
      if (number == randomnumber)
          return 0;
  
      else if (number &lt; randomnumber)
          return -1;
  
      else if (number &gt; randomnumber)
          return 1;
  
  }
  </code></pre>
  
  <p>why is this giving me  a missing return statment error? every if/else has a return
  the error comes up for the last bracket </p>