in reply to Find common lines in multiple files?

Yes.

The most relevant thing to realize about the intersection of n sets is, that intersection is an associative (and also commutative) operation, so that for computing

A ∩ B ∩ C ∩ D ...

, you can simply compute iteratively

(((A ∩ B) ∩ C) ∩ D) ...

So all that's needed is to find a way to find the intersection of two sets. This is a faq, see perlfaq4, How do I compute the intersection of two arrays?.

Reading the information into memory and outputting the result is left as an exercise to the reader.

  • Comment on Re: Find common lines in multiple files?