title: Why there is infinite loop?c++
body: <pre><code>do{
      cout &lt;&lt; "your number"; cin &gt;&gt; z;
  
  
     if (z &gt; 4){
      cout &lt;&lt; "invalid answer" &lt;&lt; endl;}
     else if (z == 4){
     cout &lt;&lt; " no" &lt;&lt; endl;}
     else {
     cout  &lt;&lt;"great!"   &lt;&lt; endl; }
  } while (z != 3, 2, 1);
  }
  </code></pre>
  
  <p>In my oppinion it's: bring up "your number" until z is 3 or 2 or 1? What's wrong?'</p>