title: C upper case to lower case
body: <p>I am having issue with lower casing my words that are being used as inputs. So my program takes in words and sorts them alphabetically and removes duplicates. But I'd like to change words upper case and lower them to equal to lower case words.</p>
  
  <p>example: <code>Apple</code> changes to <code>apple</code> </p>
  
  <p>my input:</p>
  
  <p><code>./a.out Orange apple banana Apple banana</code></p>
  
  <p>my output:</p>
  
  <pre><code>Apple
  Orange
  apple
  banana
  </code></pre>
  
  <p>Here is what I am trying to achieve</p>
  
  <p>output:</p>
  
  <pre><code>apple
  banana
  orange
  </code></pre>
  
  <p>Here is my code</p>
  
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;string.h&gt;
  
  int main(int argc, char* argv[]) {
    int i, j, k, size;
    size = argc -1;
    char *key;
    char* a[argc-1];
  
    for (i = 2; i &lt; argc; i++) {
      key = argv[i];
  
      j = i-1;
      while (j &gt;= 1 &amp;&amp; strcmp(argv[j], key) &gt; 0) {
        argv[j+1] = argv[j];
        j--;
      }
  
      argv[j+1] = key;
    }
  
    if (argc &gt; 1){
        for (i = 1; i &lt; argc;){
          puts(argv[i]);
  
          while (argv[++i] != NULL &amp;&amp; strcmp(argv[i - 1], argv[i] ) == 0)
            continue;
        }
    }
  
    return 0;
  }
  </code></pre>