title: MKMapView NSInvalidArgumentException Invalid Region crash in ios
body: <p>I am getting the error  "Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'Invalid Region ' " in my piece of code.This is the code:</p>
  
  <pre><code>- (MKCoordinateRegion)region
  {
      MKCoordinateSpan span;
      span.latitudeDelta = (maxLat + 90) - (minLat + 90);
      span.longitudeDelta = (maxLon + 180) - (minLon + 180);
  
      NSLog(@"value of lat delta %f",span.latitudeDelta);
      NSLog(@"value of long delta %f",span.longitudeDelta);
  
      if(span.latitudeDelta == 0.0f)
      span.latitudeDelta = 0.1f;
      if(span.longitudeDelta == 0.0f)
      span.longitudeDelta = 0.1f;
  
      CLLocationCoordinate2D center;
      center.latitude = minLat + span.latitudeDelta / 2;
      center.longitude = minLon + span.longitudeDelta / 2;
  
      return MKCoordinateRegionMake(center, span);
  }
  </code></pre>
  
  <p>Here the center.latitude and center.longitude are getting zero and its getting crashed.
  values for maxlat, maxlon, minlat and minlon are 
  maxLat = -91, minLat =  91, maxLon = -181, minLon =  181
  Kindly help me with this.</p>