title: A random number between 1 and 4 that's not another random number
body: <p>For some reason the following code doesn't work.</p>
  
  <pre><code>var a1 = Math.floor(Math.random()*4+1); 
  
  //Answer2
  for(a2 = 0; a2 != a1 &amp;&amp; a2 != 0; a2 = Math.floor(Math.random()*4+1)){
      alert(a2);
  }
  </code></pre>
  
  <p>I'm trying to get "a2" to be a int from 1-4 but not equivalent to "a1".</p>
  
  <p>What's wrong? 
  Thanks in advance!!!</p>
  
  <p>EDIT:</p>
  
  <p>Thank you all for your help!
  Here's my final result:</p>
  
  <pre><code>var a1, a2;
  a1 = Math.floor(Math.random()*4+1); 
  a2 = a1;
  
  while(a2 == a1){
          a2 = Math.floor(Math.random() * 3 + 1);
          alert(a2);
  }
  </code></pre>