title: Pint all the odd numbers between 2 numbers using pointer and array
body: <p>I don't know what's wrong with the code but segmentation fault is coming up.</p>
  
  <p>If l=2 and k= 5 then output should be 3 5</p>
  
  <pre><code>#include&lt;stdio.h&gt;
  int* odd(int,int,int*);
  int main()   
  {
      int l,k,*count;
      int o;
      o=0;
      printf("enter l and k");\\entering the lest and right limit\\
      scanf("%d%d",&amp;l,&amp;k);
      count= odd(l,k,&amp;o);\\passing address of o so i can get the count of 
                           loop using pointer\\
      for(int j=0;j&lt;=(o);j++)
      printf("%d",*(count +j));
  }
  int* odd(int l,int k,int * o)
  {
      int t[10],m=0;
  
      for(int i=l;i&lt;=k;i++)
      {
      if(i/2!=0)
      {
      t[m]=i;
      m++;
      }
      }
      *o=m;(using pointer to get count of loop)
      return(&amp;t[0]);
  }
  </code></pre>