title: warning: comparison between pointer and integer [enabled by default] in c
body: <p>I want to check whether the user input contains only digits or not. So, I use the following code:</p>
  
  <pre><code>for(i = 0; argv[1][i] != NULL; i++)
      if(!isdigit(argv[1][i]))
      {
          printf("Error");
          return -1;
      }
  </code></pre>
  
  <p>It works well but I got this warning:</p>
  
  <pre><code>warning: comparison between pointer and integer [enabled by default]
  </code></pre>
  
  <p>since <code>argv[1][i]</code> is an Integer and <code>NULL</code> is a pointer. How can I avoid such warning?</p>