Assuming array
contains an array of NSIndexPath
objects:
NSInteger someSection = ... // the section to check for
BOOL exists = NO;
for (NSIndexPath *path in array) {
if (path.section == someSection) {
exists = YES;
break;
}
}
if (exists) {
// Yes, at least one of the index paths was for the desired section
}