title: Check if all objects in an NSArray are identical
body: <p>I have searched this on the internet, but have found no solution...</p>
  
  <p>Here is what I want:</p>
  
  <p>Say I have an <code>NSArray</code> with three objects. These three objects are: </p>
  
  <pre><code>{
  
  @"Hi",
  @"Hi",
  @"Hi"
  
   }
  </code></pre>
  
  <p>In this case the array contains three strings, which are all equal. </p>
  
  <p>I want to testify for this, I want to create an <code>NSArray</code> category <code>BOOL</code>method that loops through all the objects and returns <code>YES</code> if they are all identical. Here is an example:</p>
  
  <pre><code>NSArray *array = [[NSArray alloc] initWithObjects: @"Object", @"Object", @"Object", nil];
  
  if ([array allObjectsAreIdentical /* method I would have to create */) {
  
       NSLog(@"All objects in this array are identical");
  }
  </code></pre>
  
  <p>I am pretty sure that there is no built in method for this, and also I would prefer not to take the tedious route and manually compare each object.</p>
  
  <p>Thanks!</p>