title: Objective C - iPhone comparing 2 CLLocations /GPS coordinates
body: <p>Ok , so thanks to Claus Broch I made some progress with comparing two GPS locations. I need to be able to say "IF currentlocation IS EQUAL TO (any GPS position from a list ) THEN do something</p>
  
  <p>My code at the moment is :</p>
  
  <p><code>CLLocationCoordinate2D bonusOne;
      bonusOne.latitude = 37.331689;
      bonusOne.longitude = -122.030731;</code></p>
  
  <p>Which is the simulators GPS location at Infinite Loop</p>
  
  <pre><code>CLLocation *loc1 = [[CLLocation alloc] initWithLatitude:bonusOne.latitude longitude:bonusOne.longitude];
  double distance = [loc1 getDistanceFrom:newLocation];
  if(distance &lt;= 10000000) {
  </code></pre>
  
  <p>Then do something
  }</p>
  
  <p>Any number under 10000000 and it assumes that there is no match.</p>