How can I compare a letter from a string in C? : <pre><code>char* str = "Hello"

if ( str[0] == 'a' ) {
  printf("OK");
}
</code></pre>

<p>I tried this but get an error, how am i suppose to comapre them?</p>
