title: Assign value to pointer in C
body: <p>I need to place * on every lowercase letter, but my program blocks always. Although this seems like a simple problem I cant find simple solution. Please help.</p>
  
  <pre><code>#include &lt;stdio.h&gt; 
  
  void f(char *p)
  {
      int i = 0;
      char c = '*';
      while(p[i] != '\0')
      {
          if(p[i]&gt; 96 &amp;&amp; p[i] &lt; 122 )
          {
              p[i] = c; # here program block
          }
          i++;
      }
      printf("%c",p);
  }
  
  int main(void)
  {
      f("tesT");
      return 1;
  }
  </code></pre>
  
  <p>I found some similar problems on internet but without success. :( </p>