Say you have a double-nested for, like when you are trying to see if an item in one unsorted array is inside another unsorted array. So for example say you have 2 lists candidates
and corruptPeople
, you're going through the candidates
and skipping those that are listed in corruptPeople
.
for( int i = 0 ; i < lenCandidates ; i++ )
{
// veto candidates[i] if candidates[i] is in corruptPeople at all
for( int j = 0 ; j < lenCorruptPeople ; j++ )
if( candidates[i] == corruptPeople[j] )
break_this_loop_and_then_continue_outer_loop ;
// initiate the eligible candidates
initiate( candidates[i] ) ;
}