 - (void) removeSong: (NSString *)zSong{      //remove from reference playlist      NSSet *targets = [self lookUpTitle:zSong];      if ([targets count]>0) {         [self.masterSongs minusSet:targets];          for (Playlist *playlist in listOfPlaylists) {             // -all objects converts the set into array.              [playlist.songList removeObjectsInArray:[targets allObjects]];         }     }     else         ; }   - (NSSet *) lookUpTitle: (NSString *)aName {      NSString *filters = @"%K CONTAINS [cd] %@";     NSPredicate *filter = [NSPredicate predicateWithFormat:filters, @"title", aName];      NSSet *result = [masterSongs filteredSetUsingPredicate:filter];      if ([result count] == 0) {         NSLog(@"not found");          return nil;     }     else{         return result;     } }  