title: How to i convert a method to a MACRO in objective C
body: <p>I have this method which basically adds the letters to the contents in an array (demonstration)</p>
  <pre><code>- (NSMutableArray *) addTheLetterZ:(NSArray *)array {
      NSMutableArray *addedLetterArray = [[NSMutableArray alloc] init];
      [array enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) {
          [addedLetterArray addObject:[NSString stringWithFormat:@&quot;%@ Y&quot;, obj]];
      }];
      [array enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) {
          [addedLetterArray addObject:[NSString stringWithFormat:@&quot;%@ Z&quot;, obj]];
      }];
      return addedLetterArray;
  }
  </code></pre>
  <p>I have 2 doubts:</p>
  <ol>
  <li><p>Can any method be converted to a macro?</p>
  </li>
  <li><p>Is there a general rule of thumb to follow when converting a function to a macro?</p>
  <p>I have looked at other <a href="https://stackoverflow.com/questions/5715021/objective-c-how-to-write-a-macro">questions</a> but even in their solutions i get an error when i try the do-loop solution to convert this method to a macro.</p>
  </li>
  </ol>