title: Odd bug converting char to int (Objective C)
body: <p>I have an app set up where I convert an NSString into an array of char variables, and I'm trying to convert some of the chars to integers (basically to parse the numbers out of the string). But when I try to convert them to int variables, they suddenly change value.</p>
  
  <p>For example:</p>
  
  <pre><code>char thechar = array[7]; //to make sure the issue isn't related to the array
  
  NSLog(@"%c %i %i",thechar,(int) thechar, [[NSNumber numberWithUnsignedChar:thechar] intValue]);
  </code></pre>
  
  <p>returns this:</p>
  
  <pre><code>3 51 51
  </code></pre>
  
  <p>Both methods (that I've found) of converting it seem to change the value to 51. Does anyone know what might be happening?</p>