title: How to assign an int range to an input in an if statement
body: <p>I'm having trouble after search for this last hour on how to implement this:</p>
  
  <pre><code>    if (age &lt; 16)
      {
          System.out.println ("You can't drive " + name);
      }
      else if (age == 16-17)
      {
          System.out.println ("You can drive but you can't vote " + name);
      }
      else if (age == 18-24)
      {
          System.out.println ("You can vote but you can't rent a car " + name);
      }
      else
      {
          System.out.println ("You can do anything you wish " + name);
      }
  </code></pre>
  
  <p>I'm just not sure how to make an input value equal to a group or range of numbers. I have been researching for the last hour, and I just can't seem to find an easy way to implement a range of numbers and assign them to something in an if statement. This code actually works, but if any int is > 16 it defaults to the else statement.</p>