Every element of @answers gets assigned to the variable $string in turn.
There are several perl functions that can be used to call external programs. system() is one of them. One respect in which the functions differ is in their return values.
You mean, it's faster to do N * 2 comparisons than 2 * N comparisons?
If you really care, benchmark. Both will do the same amount of comparisons, but the grep probably uses less opcodes. On top of that, the grep only does one assignment/push per array. Regardless of the number of matches.
Not that I care. I find the grep version clearer: the important part is the modification (setting or pushing) of the arrays, and they are in front with the grep solution, instead of buried inside the foreach.
And in general, I'd prefer a solution that doesn't need indentation over one that goes two levels deep. (Deepness of indentation is a rough estimate of complexity (yeah, yeah, hold the counterexamples)).