title: Return to NSArray matching cross criteria
body: <p>I'm trying to return objects to an NSArray when they match 1 or more criteria (kOption).
  The code I came out with works well if I have kOption1 OR kOption2 OR kOption3 and so on, but if I have kOption1 AND KOption2 it will just return the first.</p>
  
  <p>I just started programming and I'm trying to figure out how to get ou of this without having to write tons of if/else nested condition. Or is this the way I have to go?</p>
  
  <p>Thank you.  </p>
  
  <pre><code>if ([[NSUserDefaults standardUserDefaults] boolForKey:kOption1]) {
  
      return [BOTManagedObjectContext searchObjectsForEntity:@"Sede"
                                               withPredicate:[NSPredicate predicateWithFormat:@"(idTipoSede != %d) AND (idTipoSede != %d)", kTipoSedePrivata, kTipoSedeDayOff]
                                                     sortKey:nil
                                               sortAscending:NO];
  
  
  } if ([[NSUserDefaults standardUserDefaults] boolForKey:kOption2]) {
  
      return [BOTManagedObjectContext searchObjectsForEntity:@"Sede"
                                               withPredicate:[NSPredicate predicateWithFormat:@"(idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d)", kTipoSedeVenue, kTipoSedeArci, kTipoSedeSquat, kTipoSedeGalleria, kTipoSedeHouse, kTipoSedeFestival]
                                                     sortKey:nil
                                               sortAscending:NO];
  
  
  } if ([[NSUserDefaults standardUserDefaults] boolForKey:kOption3]) {
  
      return [BOTManagedObjectContext searchObjectsForEntity:@"Sede"
                                               withPredicate:[NSPredicate predicateWithFormat:@"(idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d) OR (idTipoSede = %d)", kTipoSedeVenue, kTipoSedeArci, kTipoSedeSquat, kTipoSedeGalleria, kTipoSedeHouse, kTipoSedePromoter]
                                                     sortKey:nil
                                               sortAscending:NO];
      } else {
         return [something else...];
  }
  </code></pre>