title: "and" and "or" statements in java
body: <p>I have a question about "and" and "or' statements in java.  Is there a way to use both of them in the same if statement?</p>
  
  <p>for example:</p>
  
  <pre><code>if(a==max &amp;&amp; b==0) || (a==max &amp;&amp; c==0){
      a==0;
  } else { 
       a==max;
  }
  </code></pre>
  
  <p>is this legal?</p>