title: How to find the length of argv[] in C
body: <pre><code>#include &lt;stdio.h&gt;
  #include &lt;stdlib.h&gt;
  #include &lt;string.h&gt;
  
  int main(int argc, char *argv[]){
      int fir; //badly named loop variable
      char *input[] = calloc( strlen(argv), sizeof(char)); //initializing an array
      for( fir = 1; fir&lt; strlen(argv); fir++){ //removing the first element of argv
          strcat(input, argv[fir]); // appending to input
      }
  }
  </code></pre>
  
  <p>The error I'm getting is for line 7. It says "passing argument 1 of 'strlen' from incompatible pointer type". I get the same error for the <code>strcat</code> function.
  It also says "given a <code>char **</code> but expected a <code>const char *</code>" for both functions.</p>
  
  <p>I'm trying to populate a new array with all the elements of <code>argv</code> except the first. I tried <code>argv = &amp;argv[1]</code> and it did not work.</p>
  
  <p>Do the <code>strlen()</code> and <code>strcat()</code> functions not take <code>char</code> arrays?</p>