title: What does if((x=0)) mean in C?
body: <p>So apparently, in gcc/C, a compiler compiles when</p>
  
  <pre><code>if ((x=0)){ some code }
  </code></pre>
  
  <p>is used, while when</p>
  
  <pre><code>if (x=0){ some code }
  </code></pre>
  
  <p>is used, then compiler refuses to compile.</p>
  
  <p>What are the differences between two?</p>
  
  <p>As a note, I know what is the difference between <code>x==0</code> and <code>x=0</code>. I am just exploring how C behaves when met with some weird codes.</p>