title: NSMutableArray (addObject) not working inside if statement
body: <p>i have this code :</p>
  
  <pre><code>NSMutableArray *arr = [NSMutableArray array];
  for (int i = 0; i &lt;[titleNews count]; ++i) {
      TFHppleElement *someText =[titleNews objectAtIndex:i];
      NSString *result = [someText content];
  
      [arr addObject:result];
      if ([[arr objectAtIndex:i]isEqualToString:@"-- : --"]) {
          [arr replaceObjectAtIndex:i withObject:@"x"];
          [arr addObject:@"/"];
  
      }
  
      NSLog(@"%@",[arr objectAtIndex:i]);
  }
  </code></pre>
  
  <p>the (replaceObjectAtIndex: withObject:) work fine but the (addObject)method not working</p>