title: what is the default value of int datatype in c?
body: <pre class="lang-c prettyprint-override"><code>#include &lt;stdio.h&gt;
  
  void main(int x)
  {
  
      printf(&quot;%d&quot;,x);
      
      return 0;
  }
  </code></pre>
  <p>If we print x value in main() function it will show 0
  and as the default value of int is 0.
  when i add int x as a parameter in main() it prints x value is 1.
  Why?</p>