for ( grep { filter($_) } @big_array ) { # do stuff }