title: Switch case for cli arguments in C
body: <p>I'm grabbing CLI args via argc and argv in C. I'd like to use a switch case to do different things depending on the arguments passed. In my case, <code>cli u</code> will print &quot;Updating...&quot;</p>
  <p>Here's what I've got so far:</p>
  <pre class="lang-c prettyprint-override"><code>#include &lt;stdio.h&gt;
  
  int main(int argc, char *argv[]) {
    switch(argv[0]){
      case &quot;t&quot;:
        printf(&quot;Updating...&quot;)
        break;
      default:
        printf(&quot;Welcome!&quot;)
    }
    return 0;
  }
  </code></pre>
  <p>But I'm getting <code>switch quantity not an integer</code> on <code>argv[0]</code>.</p>
  <p>I'd like to use switch cases because this'll be a lengthy program. Thanks, and cheers!</p>