title: Turning an NSString to an Integer and checking whether it is less than or equal to a value
body: <p>I have a project that returns a distance as an NSString. I want to check that distance to see if it is less or equal to, or more than 10,000 feet. I am running into an error that says "Implicit conversion of 'int' to 'NSString *' is disallowed with ARC." Does anyone know how to convert the NSString into an Integer? or how to construct the code? Thank you!   </p>
  
  <pre><code>- (IBAction)btnPress:(id)sender {
  
  NSString *distanceInFeet = [[NSUserDefaults standardUserDefaults]
                             stringForKey:@"distanceInFeet"];
  
  if ([distanceInFeet intValue] &lt;= 10000)
  {
  
      UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Close" message:@"Distance is close" delegate:self cancelButtonTitle:@"Dismiss" otherButtonTitles:nil, nil];
      [alert show];
      return;
  
  else
  {
      UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Far" message:@"Distance is far" delegate:self cancelButtonTitle:@"Dismiss" otherButtonTitles:nil, nil];
      [alert show];
      return;
  }
  
  } 
  </code></pre>