title: pointer default value .?
body: <p>Look, </p>
  
  <pre><code>  typedef struct jig 
     { 
           int *a;
           int *b;
     }temp;
  </code></pre>
  
  <p><strong>now stage 1</strong> :</p>
  
  <pre><code>temp *b;
  b= (temp*)malloc(sizeof(temp));
  
  if(b-&gt;a != NULL)
      printf("a is not null\n");
  else
      printf("a is null\n");
  if(b-&gt;b != NULL)
      printf("b is not null\n");
  else
      printf("b is null\n");
  </code></pre>
  
  <p>output is : </p>
  
  <pre><code>a is null
  b is null
  </code></pre>
  
  <p><strong>now stage 2</strong> :</p>
  
  <pre><code>temp b;
  
  if(b.a != NULL)
      printf("a is not null\n");
  else
      printf("a is null\n");
  if(b.b != NULL)
      printf("b is not null\n");
  else
      printf("b is null\n");
  </code></pre>
  
  <p>output is :</p>
  
  <pre><code>a is not null
  b is not null
  </code></pre>
  
  <p>why this is happening?</p>